Skip to content

基于 Itchat 为 Python Wechaty 实现社区首个 Python 语言的本地 Puppet #75

Description

@huan

开源软件供应链点亮计划

“开源软件供应链点亮计划-暑期2021”(以下简称 暑期2021)是由中科院软件所与 openEuler 社区共同举办的一项面向高校学生的暑期活动,旨在鼓励在校学生积极参与开源软件的开发维护,促进国内优秀开源软件社区的蓬勃发展。

根据项目的难易程度和完成情况,参与者还可获取“开源软件供应链点亮计划-暑期2021”活动奖金和奖杯。

官网:https://summer.iscas.ac.cn

Wechaty

Wechaty 是一个开源聊天机器人框架SDK,具有高度封装、高可用的特性,支持NodeJs, Python, Go 和Java 等多语言版本。在过去的5年中,服务了数万名开发者,收获了 Github 的 9600 Star。同时配置了完整的DevOps体系并持续按照Apache 的方式管理技术社区。

项目名称

基于 ItchatPython Wechaty 实现社区首个 Python 语言的本地 Puppet

背景介绍

Wechaty 社区目前已经支持微信、Whatsapp、企业微信、飞书等常见流行即时通讯工具,并且能够通过多语言 SDK (比如 Python Wechaty) 进行调用。

Python Wechaty 目前通过 Puppet Service 模块,基于 gRPC 与 TypeScript 语言的服务器进行通讯,实现对 Python 语言的支持。

我们在本次 Summer 2021 的项目中,希望可以开发一个基于 Python 语言的 Wechaty Puppet Provider 实现(模块名:wechaty-puppet-itchat),通过封装 Itchat ,使其成为 Python Wechaty 可以使用的社区生态模块。

需求介绍

使用 https://github.com/wechaty/python-wechaty-puppet-service 项目作为模版,将核心代码文件 https://github.com/wechaty/python-wechaty-puppet-service/blob/master/src/wechaty_puppet_service/puppet.py 中的 gRPC 调用,全部替换(封装)为 Itchat 模块的调用。

在初期开发中,能够实现文本消息的接收和发送,即可完成原型验证 POC 。

除了 Python 代码之外,还可以参考以下两个链接:

  1. TypeScript Puppet Official Documentation: https://wechaty.github.io/wechaty-puppet/typedoc/classes/puppet.html
  2. Wechaty Puppet Specification: https://wechaty.js.org/docs/specs/puppet

项目难度

中(奖金:9000元)

导师联系方式

吴京京:Python Wechaty creator, Wechaty committer, Microsoft Research Asia Intern

项目产出目标

  1. 每日代码 commit
  2. 每周提交一份 report (回复本 issue)
  3. 每两周一次在线会议
  4. 发布 Git Repo python-wechaty-puppet-itchat
  5. 可以通过 Python Wechaty 加载 wechaty-puppet-itchat 模块,并通过 itchat 底层,实现文本消息的收发功能
  6. 提供一个 examples/ding-dong-bot.py ,完成“接收到文字消息ding时,自动回复消息dong"的功能
  7. 配置 GitHub Actions 实现自动化测试* (可选)

项目技术栈

  1. Python programming language
  2. Git
  3. Pypi / pip tools

Hello students!

We want Wechaty to be the universal instant messaging SDK on all IM platforms for chatbot makers to build their great conversational user interface, so while these are our ideas of what we think would make good projects for the summer, we're eager to hear your ideas and proposals as well.

Try us out and get to know the Wechaty code with examples!

What we want to do

Implement Itchat Puppet (ItChat) for Python Wechaty. The Puppet abstraction allows Wechaty to provide a consisting API on all IM platforms for build a chatbot. We have lots of puppet providers in TypeScript already, and we want to support our first Python Wechaty Puppet so that our Python developers can run their chatbots out-of-the-box with the Web protocol of WeChat.

  • Required skills: Python programming language, ItChat.
  • Likely mentors: @huan.

Useful Links

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions