mirror of
https://github.com/infiniflow/ragflow.git
synced 2026-03-08 00:56:02 +08:00
Feat: published agent version control (#13410)
### What problem does this PR solve? Feat: published agent version control ### Type of change - [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
@ -1593,6 +1593,10 @@ Creates a session with the current agent.
|
||||
|
||||
The parameters in `begin` component.
|
||||
|
||||
Also supports:
|
||||
|
||||
- `release` (`bool | str`, optional): Set to `True` (or `"true"`) to create the session in release mode (published version only).
|
||||
|
||||
#### Returns
|
||||
|
||||
- Success: A `Session` object containing the following attributes:
|
||||
@ -1610,6 +1614,8 @@ rag_object = RAGFlow(api_key="<YOUR_API_KEY>", base_url="http://<YOUR_BASE_URL>:
|
||||
agent_id = "AGENT_ID"
|
||||
agent = rag_object.list_agents(id = agent_id)[0]
|
||||
session = agent.create_session()
|
||||
# Or create in release mode:
|
||||
# session = agent.create_session(release=True)
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
Reference in New Issue
Block a user