Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Telegram GitHub Issue "Workroom" #25

Closed
0x4007 opened this issue Jun 25, 2024 · 33 comments · Fixed by ubiquity-os-marketplace/ubiquity-os-kernel-telegram#2
Closed

Telegram GitHub Issue "Workroom" #25

0x4007 opened this issue Jun 25, 2024 · 33 comments · Fixed by ubiquity-os-marketplace/ubiquity-os-kernel-telegram#2

Comments

@0x4007
Copy link
Member

0x4007 commented Jun 25, 2024

I realize that some projects require collaboration, and our team has a natural tendency to direct message each other. The problem with this approach is that the collaborative research in direct messages is not auditable. The conversation that occurred would be useful for future reference to post a summary to the completed task.

It would be nice if as soon as a task is started, the bot can post a link to a freshly generated telegram chat room that acts as a collaborative "work room" to solve that particular task

Once the task is closed as complete, we can use ChatGPT to summarize the essential details from the telegram group chat and post it to the GitHub issue as a conversation summary for future reference

Inventing the telegram integration will probably take some time so I'll set this to a week.


It would be nice to get automatically kicked from the chat when the task is completed so that our telegrams don't get cluttered with these.

@jordan-ae
Copy link

/start

Copy link

ubiquibot bot commented Jul 8, 2024

DeadlineMon, Jul 15, 9:47 AM UTC
Registered Wallet 0x2F05fD58023B0a95d1866aa0A3b672cEf05945c5
Tips:
  • Use /wallet 0x0000...0000 if you want to update your registered payment wallet address.
  • Be sure to open a draft pull request as soon as possible to communicate updates on your progress.
  • Be sure to provide timely updates to us when requested, or you will be automatically unassigned from the task.

Copy link

ubiquibot bot commented Jul 25, 2024

# No linked pull requests to close

@jordan-ae
Copy link

/start

Copy link

ubiquibot-dev bot commented Aug 8, 2024

DeadlineThu, Aug 15, 12:06 PM UTC
Registered Wallet 0x2F05fD58023B0a95d1866aa0A3b672cEf05945c5
Tips:
  • Use /wallet 0x0000...0000 if you want to update your registered payment wallet address.
  • Be sure to open a draft pull request as soon as possible to communicate updates on your progress.
  • Be sure to provide timely updates to us when requested, or you will be automatically unassigned from the task.

Copy link

ubiquibot bot commented Aug 8, 2024

Warning! This task was created over 44 days ago. Please confirm that this issue specification is accurate before starting.
DeadlineThu, Aug 15, 12:06 PM UTC
Registered Wallet 0x2F05fD58023B0a95d1866aa0A3b672cEf05945c5
Tips:
  • Use /wallet 0x0000...0000 if you want to update your registered payment wallet address.
  • Be sure to open a draft pull request as soon as possible to communicate updates on your progress.
  • Be sure to provide timely updates to us when requested, or you will be automatically unassigned from the task.

Copy link

ubiquibot bot commented Aug 9, 2024

# No linked pull requests to close

Copy link

ubiquibot bot commented Aug 9, 2024

@jordan-ae the deadline is at 2024-08-16T12:35:35.674Z

@DivineDB
Copy link

/start

Copy link

ubiquibot bot commented Aug 10, 2024

! Skipping '/start' because the issue is already assigned.

@jordan-ae
Copy link

@0x4007 I encountered a blocker with the Telegram integration plugin. Initially, the plan was to create a bot using BotFather, similar to our previous Telegram bot. However, according to Telegram's latest documentation, bots are unable to create Telegram channels—only human users can do this, likely to prevent spamming.

To work around this limitation, I opted to use the gram-js library, which allows us to create channels via a Telegram app associated with an existing user account. The challenge here is that Telegram requires a phone number for authentication and sends a code that must be manually entered to pass 2FA. Fortunately, this authentication process only needs to be done once. After the first successful authentication, a session string is generated. This session string remains valid indefinitely unless explicitly revoked, so we won’t need to re-authenticate in the future.

Given this requirement, we'll probably have to create a dedicated Telegram user for Ubiquity, which will be used to power the plugin.

I've made some progress and have successfully managed to create a Telegram channel when a task starts and close/delete the channel when the task is completed. I'm submitting a PR with the current state of the implementation asap.

@0x4007
Copy link
Member Author

0x4007 commented Aug 16, 2024

https://t.me/UbiquityOS is ready to be used.

@Keyrxng Keyrxng assigned Keyrxng and unassigned jordan-ae Aug 30, 2024
@Keyrxng
Copy link
Member

Keyrxng commented Aug 30, 2024

QA: ubq-testing/telegram-bot#4 (comment)

It is not based on https://github.com/ubiquity/ubiquibot-telegram at all and uses the plugin-template as a foundation. I'll create a repo I can PR against as it looks like the one I made was deleted (I'm confident that I did make it)

@0x4007
Copy link
Member Author

0x4007 commented Aug 31, 2024

Perhaps there is an opportunity to use Telegram apps to solve this problem somehow.

@Keyrxng
Copy link
Member

Keyrxng commented Aug 31, 2024

Perhaps there is an opportunity to use Telegram apps to solve this problem somehow.

That's essentially what I have been trying I'm sure as the MTProto API is for clients and apps as far as I understand it while the Bot API is a simplified rest api.

or do you mean mini apps?

@Keyrxng
Copy link
Member

Keyrxng commented Aug 31, 2024

0x4007 via telegram:

  1. Bot makes group chat
  2. Bot posts link when task is priced.
  3. Task is closed and bot kicks everybody from group chat
    People manually join by using the link

So a new issue is created and after a price label is applied the bot creates a workroom, which is it's own telegram group chat and it posts a link to it.

At this point no one is in it so the core team member(s) assigning the labels and creating the task should be required to join the workroom immediately so there is at least one person in it in the event a contributor joins it. So they'd effectively be the 'knowledge base' for that task via telegram pretty much?

Should our telegram bot also be invited into the chat directly too?


We'll need to create db entry for each chat that we create and have the plugin event run on issues.labeled or similar as issues.opened doesn't work with this approach. We'd check if a chat exists in supabase for that task, create if not. So for every new issue we'll need to store taskTitle, chatId, embeddings.

If we kick everyone from the chat once the issue is complete and then the issue is reopened should we post a new chatroom link or the same link for the original chat?

Should we standardize workroom titles with a prefix/format or just use the raw task title?

@Immanuel-john

This comment was marked as off-topic.

@anonyphoenix

This comment was marked as outdated.

@Keyrxng
Copy link
Member

Keyrxng commented Oct 22, 2024

@0x4007 can this be assigned to me and reward generated please. As far as I can tell I have met and achieved the spec, provided ample QA, docs and tutorials to properly setup and install this plugin.

@0x4007
Copy link
Member Author

0x4007 commented Oct 24, 2024

@gentlementlegen i understand theres been more set up required i presume i should assign both of you

@gentlementlegen
Copy link
Member

I spent quite some time on the setup because it is complex and @Keyrxng didn't have enough access to the configuration or the Cloudflare, but to be honest I didn't code anything in here.

@Keyrxng
Copy link
Member

Keyrxng commented Oct 24, 2024

And I spent almost as much writing docs, recording tutorials and trying to assist in the setup process.

Sorry and thanks @gentlementlegen, I'm just as glad as you that it's behind us now lmao.

Copy link

@Keyrxng the deadline is at Thu, Oct 31, 11:50 PM UTC

@0x4007 0x4007 closed this as completed Oct 24, 2024
Copy link

ubiquity-os-beta bot commented Oct 24, 2024

! Failed to run comment evaluation. Relevance / Comment length mismatch!

@gentlementlegen
Copy link
Member

Not the first time this error pops up, I wonder if it is just OpenAI not returning the proper JSON response or the logic being flawed.

@0x4007 0x4007 reopened this Oct 26, 2024
@0x4007 0x4007 closed this as completed Oct 26, 2024
Copy link

ubiquity-os-beta bot commented Oct 26, 2024

! Failed to run comment evaluation. Relevance / Comment length mismatch!

@0x4007
Copy link
Member Author

0x4007 commented Oct 26, 2024

Not the first time this error pops up, I wonder if it is just OpenAI not returning the proper JSON response or the logic being flawed.

@gentlementlegen You need to implement a fix

Copy link

+ Evaluating results. Please wait...

Copy link

Note

This output has been truncated due to the comment length limit.

 [ 614.13975 WXDAI ] 

@Keyrxng
Contributions Overview
ViewContributionCountReward
IssueTask1600
IssueComment614.13975
ReviewComment680

 [ 6.99 WXDAI ] 

@jordan-ae
Contributions Overview
ViewContributionCountReward
IssueComment16.99

 [ 220.122 WXDAI ] 

@0x4007
Contributions Overview
ViewContributionCountReward
IssueSpecification179.11
IssueComment56.417
ReviewComment44134.595

 [ 103.803 WXDAI ] 

@gentlementlegen
Contributions Overview
ViewContributionCountReward
IssueComment26.471
ReviewComment2097.332

 [ 53.127 WXDAI ] 

@rndquu
Contributions Overview
ViewContributionCountReward
ReviewComment253.127

@0x4007
Copy link
Member Author

0x4007 commented Nov 28, 2024

The conversation that occurred would be useful for future reference to post a summary to the completed task.

I've never seen a summary posted are you sure this is implemented to spec?

@Keyrxng
Copy link
Member

Keyrxng commented Nov 28, 2024

I've never seen a summary posted are you sure this is implemented to spec?

  1. That wasn't implemented no.
  2. During review it wasn't mentioned and we had discussed embedding the TG conversation history etc as well and the PR was being pushed for merge so nothing else was implemented beyond initial functionality.
  3. This task was really under-priced for the amount of time, effort and work involved in building the infra and the features included in V2 init ubiquity-os-marketplace/ubiquity-os-kernel-telegram#2 compared to other from-the-ground plugins. A couple of your comments speak to that, so I'd appreciate a new clear spec and for it to be priced please.

Pretty interesting and wild architecture where we're able to procure the benefits from both workers and actions.

Maybe this is the future of plug-in development

P.S:

Apprecaite if you could fix this for me also, cheers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants