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

feat(product-assistant): a human in the loop for the taxonomy agent #26767

Open
wants to merge 66 commits into
base: master
Choose a base branch
from

Conversation

skoob13
Copy link
Contributor

@skoob13 skoob13 commented Dec 9, 2024

Problem

If the request is ambiguous or the taxonomy doesn't provide a clear picture, we should ask the user to clarify their request.

Demo
2024-12-12 19 47 34

Changes

  • Add a checkpointer implementation on Django for LangGraph.
  • Threads are now stored in the database (+ checkpoints, checkpoint writes, and checkpoint blobs).
  • Implement a human in the loop for the taxonomy agent.
  • Refactor how we restore a conversation since human messages can now appear in any order.
  • Move the assistant to its endpoint.
  • Use Pydantic for the state to simplify further state serialization.
  • Add more tests.

Further work:

  • Improve serialization of checkpoints. I've decided to split these PRs because this appears to be more complicated than I expected.
  • Improve frontend UI, so users can easily search and add specific events to a prompt.
  • Add eval tests.

Does this work well for both Cloud and self-hosted?

No

How did you test this code?

Manual testing, Storybook, more unit tests.

ee/api/conversation.py Fixed Show fixed Hide fixed
@posthog-bot
Copy link
Contributor

📸 UI snapshots have been updated

8 snapshot changes in total. 0 added, 8 modified, 0 deleted:

  • chromium: 0 added, 8 modified, 0 deleted (diff for shard 1)
  • webkit: 0 added, 0 modified, 0 deleted

Triggered by this commit.

👉 Review this PR's diff of snapshots.


class Conversation(UUIDModel):
user = models.ForeignKey(User, on_delete=models.CASCADE)
team = models.ForeignKey(Team, on_delete=models.CASCADE)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now, I think that there should be a ref to the project because property values can differ. @Twixes what do you think?

@posthog-bot
Copy link
Contributor

📸 UI snapshots have been updated

10 snapshot changes in total. 0 added, 10 modified, 0 deleted:

  • chromium: 0 added, 10 modified, 0 deleted (diff for shard 1)
  • webkit: 0 added, 0 modified, 0 deleted

Triggered by this commit.

👉 Review this PR's diff of snapshots.

@skoob13 skoob13 requested a review from Twixes December 12, 2024 18:59
@skoob13 skoob13 marked this pull request as ready for review December 12, 2024 18:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants