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

Demo #264

Open
wants to merge 9 commits into
base: main
Choose a base branch
from
Open

Demo #264

wants to merge 9 commits into from

Conversation

XuhuiZhou
Copy link
Member

Closes #

📑 Description

✅ Checks

  • My pull request adheres to the code style of this project
  • My code requires changes to the documentation
  • I have updated the documentation as required
  • All the tests have passed
  • Branch name follows type/descript (e.g. feature/add-llm-agents)
  • Ready for code review

ℹ Additional Information

XuhuiZhou and others added 2 commits December 4, 2024 20:58
* api doc

* add PUT

* add an temp example for websocket

* websocket

* update readme

* Update README.md

* update websocket live simulation api doc

* [autofix.ci] apply automated fixes

* update websocket doc

* add api server with websocket as well as a client

* fix mypy errors

* support stopping the chat

* add 404 to the status code

* fix mypy issue

* update the returned message types

* redesign websocket api

* update websocket, fix mypy error

* add example of using websocket

* clean code & change to existing functions for simulation

* fix typing mismatch

* update doc & mypy type fix

* add type check for run_async_server

* move example

---------

Co-authored-by: Hao Zhu <prokilchu@gmail.com>
Co-authored-by: Zhe Su <360307598@qq.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
* add customizable evaluation dimensions

* add docs

* fix mypy error & refactor examples

* add docs for evaluation dimensions

* update docs and examples

* add test cases and fix mypy issue

* fix mypy issue

* Fix test_create_custom_dimension to use CustomEvaluationDimension.get(pk) (#262)

Co-authored-by: openhands <openhands@all-hands.dev>

* Fix/custom eval dimension test (#263)

* Fix test_create_custom_dimension to use CustomEvaluationDimension.get(pk)

* Update documentation for SotopiaDimension and EvaluationDimensionBuilder

* [autofix.ci] apply automated fixes

* Add API documentation for evaluation dimensions

* Refine API documentation for evaluation_dimensions.py to match style

* [autofix.ci] apply automated fixes

---------

Co-authored-by: openhands <openhands@all-hands.dev>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* add doc

---------

Co-authored-by: XuhuiZhou <zhouxuhui2018@gmail.com>
Co-authored-by: openhands <openhands@all-hands.dev>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Copy link

codecov bot commented Dec 8, 2024

Codecov Report

Attention: Patch coverage is 56.51438% with 257 lines in your changes missing coverage. Please review.

Project coverage is 71.47%. Comparing base (61f190e) to head (ab6903a).

Files with missing lines Patch % Lines
sotopia/ui/fastapi_server.py 50.87% 140 Missing ⚠️
sotopia/database/evaluation_dimensions.py 37.09% 39 Missing ⚠️
sotopia/ui/websocket_utils.py 49.33% 38 Missing ⚠️
sotopia/server.py 71.21% 19 Missing ⚠️
tests/ui/test_fastapi.py 77.64% 19 Missing ⚠️
sotopia/database/serialization.py 0.00% 1 Missing ⚠️
sotopia/envs/parallel.py 0.00% 1 Missing ⚠️
@@            Coverage Diff             @@
##             main     #264      +/-   ##
==========================================
- Coverage   74.47%   71.47%   -3.01%     
==========================================
  Files          61       63       +2     
  Lines        3162     3684     +522     
==========================================
+ Hits         2355     2633     +278     
- Misses        807     1051     +244     
Files with missing lines Coverage Δ
sotopia/database/__init__.py 100.00% <100.00%> (ø)
sotopia/database/logs.py 94.33% <100.00%> (+0.46%) ⬆️
sotopia/database/persistent_profile.py 89.83% <100.00%> (+0.17%) ⬆️
sotopia/experimental/agents/base_agent.py 97.50% <ø> (ø)
tests/database/test_database.py 98.24% <100.00%> (+0.24%) ⬆️
tests/experimental/test_agent.py 93.02% <ø> (ø)
tests/sampler/test_sampler.py 100.00% <100.00%> (ø)
sotopia/database/serialization.py 97.87% <0.00%> (ø)
sotopia/envs/parallel.py 77.71% <0.00%> (ø)
sotopia/server.py 44.38% <71.21%> (+2.71%) ⬆️
... and 4 more

XuhuiZhou and others added 7 commits December 11, 2024 11:19
…lationshio (#265)

* temp run

* add relationship api

* fix mypy error

* update relationship api

* simulate episode non-streaming

* modify sim episodes

* add simulation status

* task error

* add background task

* [autofix.ci] apply automated fixes

* back to arun one episode

* upload the code

* use rq to execute background tasks

* temp sol

---------

Co-authored-by: Hao Zhu <prokilchu@gmail.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
* initial framework

* initial conv

* fix module error

* feat: Add 3 new features to Moderator (#266)

* feat:introduce booting procedure, saving, and ending chat to moderator

* fix: moderator will now ignore none AgentAction, Observations now don't have to include all channels in the mapping

* merge changes of example into the original one

* fix: 1. save() method now accepts push_to_db config 2. booting()'s waiting time is changed to 0.1 sec

* fix: rewrite booting() so that different agent will receive different background information

* fix: moderator now inherits from Node directly, instead of from BaseAgent

---------

Co-authored-by: JXZhou <JXZhou>

* add save condition for moderator

* push to db false

* to fully stop

* stopping all agents

* fix mypy

* fix mypy error

---------

Co-authored-by: JXZhou <156194797+JXZhou0224@users.noreply.github.com>
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