Skip to content

Commit

Permalink
update typo
Browse files Browse the repository at this point in the history
  • Loading branch information
zzhangpurdue committed May 10, 2024
1 parent f05d89c commit b571c11
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ It mainly has the following characteristics:


## 🎉 News
* 🔥May 10, 2024: Modelscope-Agent launched a user-friendly `Assistant API`, and also provided a `Tools API` that executes utilities in isolated, secure containers. , please find the [document](https://github.com/modelscope/modelscope-agent/blob/master/modelscope_agent_servers/)
* 🔥May 10, 2024: Modelscope-Agent launched a user-friendly `Assistant API`, and also provided a `Tools API` that executes utilities in isolated, secure containers, please find the [document](https://github.com/modelscope/modelscope-agent/blob/master/modelscope_agent_servers/)
* 🔥Apr 12, 2024: The [Ray](https://docs.ray.io/en/latest/) version of multi-agent solution is on modelscope-agent, please find the [document](https://github.com/modelscope/modelscope-agent/blob/master/modelscope_agent/multi_agents_utils/README.md)
* Mar 15, 2024: Modelscope-Agent and the [AgentFabric](https://github.com/modelscope/modelscope-agent/tree/master/apps/agentfabric) (opensource version for GPTs) is running on the production environment of [modelscope studio](https://modelscope.cn/studios/agent).
* Feb 10, 2024: In Chinese New year, we upgrade the modelscope agent to version v0.3 to facilitate developers to customize various types of agents more conveniently through coding and make it easier to make multi-agent demos. For more details, you can refer to [#267](https://github.com/modelscope/modelscope-agent/pull/267) and [#293](https://github.com/modelscope/modelscope-agent/pull/293) .
Expand Down
8 changes: 4 additions & 4 deletions modelscope_agent_servers/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ To interact with the chat API, you should construct a object like `ChatRequest`
An example code snippet is as follows:

```Shell
curl -X POST 'http://localhost:31512/v1/chat/completion' \
curl -X POST 'http://localhost:31512/v1/chat/completions' \
-H 'Content-Type: application/json' \
-d '{
"tools": [{
Expand Down Expand Up @@ -115,7 +115,7 @@ To enable knowledge retrieval, you'll need to include use_knowledge and files in
- `files`: the file(s) you wish to use during the conversation. By default, all previously uploaded files will be used.

```Shell
curl -X POST 'http://localhost:31512/v1/chat/completion' \
curl -X POST 'http://localhost:31512/v1/chat/completions' \
-H 'Content-Type: application/json' \
-d '{
"tools": [
Expand Down Expand Up @@ -167,14 +167,14 @@ With above examples, the output should be like this:

#### Assistant

Like `v1/chat/completion` API, you should construct a `ChatRequest` object when use `v1/assistant/lite`. Here is an example using python `requests` library.
Like `v1/chat/completions` API, you should construct a `ChatRequest` object when use `v1/assistants/lite`. Here is an example using python `requests` library.


```Python
import os
import requests

url = 'http://localhost:31512/v1/assistant/lite'
url = 'http://localhost:31512/v1/assistants/lite'

# llm config
llm_cfg = {
Expand Down
4 changes: 2 additions & 2 deletions modelscope_agent_servers/assistant_server/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ async def upload_files(uuid_str: str = Form(...),
request_id=request_id)


@app.post('/v1/assistant/lite')
@app.post('/v1/assistants/lite')
async def chat(agent_request: ChatRequest):
uuid_str = agent_request.uuid_str
request_id = str(uuid4())
Expand Down Expand Up @@ -120,7 +120,7 @@ async def chat(agent_request: ChatRequest):
return create_success_msg({'response': response}, request_id=request_id)


@app.post('/v1/chat/completion')
@app.post('/v1/chat/completions')
async def chat_completion(agent_request: ChatRequest):
uuid_str = agent_request.uuid_str
request_id = str(uuid4())
Expand Down

0 comments on commit b571c11

Please sign in to comment.