mirror of
https://github.com/agentscope-ai/ReMe.git
synced 2026-08-28 05:25:04 +00:00
docs(config): update documentation config and quick start examples
This commit is contained in:
parent
63f6796a0b
commit
82d0adc86e
3 changed files with 98 additions and 85 deletions
|
|
@ -45,6 +45,7 @@ sphinx:
|
|||
- sphinx.ext.intersphinx
|
||||
- sphinx.ext.autosummary
|
||||
- sphinxcontrib.mermaid
|
||||
- sphinx_design
|
||||
config:
|
||||
# API Documentation Configuration
|
||||
autosummary_generate: True
|
||||
|
|
@ -121,4 +122,7 @@ sphinx:
|
|||
color-admonition-background: "#f8f9fa"
|
||||
dark_css_variables:
|
||||
color-brand-primary: "#64b5f6"
|
||||
color-brand-content: "#64b5f6"
|
||||
color-brand-content: "#64b5f6"
|
||||
|
||||
# jupyter-book build --all .
|
||||
# ghp-import -n -p -f _build/html
|
||||
|
|
@ -40,7 +40,50 @@ reme \
|
|||
|
||||
#### Task Memory Management
|
||||
|
||||
```{code-cell}
|
||||
`````{tab-set}
|
||||
|
||||
````{tab-item} python(import)
|
||||
```{code-block}
|
||||
import asyncio
|
||||
from reme_ai import ReMeApp
|
||||
|
||||
async def main():
|
||||
async with ReMeApp(
|
||||
"llm.default.model_name=qwen3-30b-a3b-thinking-2507",
|
||||
"embedding_model.default.model_name=text-embedding-v4",
|
||||
"vector_store.default.backend=memory"
|
||||
) as app:
|
||||
# Experience Summarizer: Learn from execution trajectories
|
||||
result = await app.async_execute(
|
||||
name="summary_task_memory",
|
||||
workspace_id="task_workspace",
|
||||
trajectories=[
|
||||
{
|
||||
"messages": [
|
||||
{"role": "user", "content": "Help me create a project plan"}
|
||||
],
|
||||
"score": 1.0
|
||||
}
|
||||
]
|
||||
)
|
||||
print(result)
|
||||
|
||||
# Retriever: Get relevant memories
|
||||
result = await app.async_execute(
|
||||
name="retrieve_task_memory",
|
||||
workspace_id="task_workspace",
|
||||
query="How to efficiently manage project progress?",
|
||||
top_k=1
|
||||
)
|
||||
print(result)
|
||||
|
||||
if __name__ == "__main__":
|
||||
asyncio.run(main())
|
||||
```
|
||||
````
|
||||
|
||||
````{tab-item} python(http)
|
||||
```{code-block}
|
||||
import requests
|
||||
|
||||
# Experience Summarizer: Learn from execution trajectories
|
||||
|
|
@ -58,9 +101,9 @@ response = requests.post("http://localhost:8002/retrieve_task_memory", json={
|
|||
"top_k": 1
|
||||
})
|
||||
```
|
||||
````
|
||||
|
||||
|
||||
````{dropdown} curl version
|
||||
````{tab-item} curl
|
||||
```bash
|
||||
# Experience Summarizer: Learn from execution trajectories
|
||||
curl -X POST http://localhost:8002/summary_task_memory \
|
||||
|
|
@ -83,7 +126,7 @@ curl -X POST http://localhost:8002/retrieve_task_memory \
|
|||
```
|
||||
````
|
||||
|
||||
````{dropdown} Node.js version
|
||||
````{tab-item} Node.js
|
||||
```{code-block} javascript
|
||||
// Experience Summarizer: Learn from execution trajectories
|
||||
fetch("http://localhost:8002/summary_task_memory", {
|
||||
|
|
@ -117,9 +160,55 @@ fetch("http://localhost:8002/retrieve_task_memory", {
|
|||
.then(data => console.log(data));
|
||||
```
|
||||
````
|
||||
`````
|
||||
|
||||
#### Personal Memory Management
|
||||
|
||||
<summary> import version</summary>
|
||||
`````{tab-set}
|
||||
|
||||
````{tab-item} Python(import)
|
||||
```{code-cell}
|
||||
import asyncio
|
||||
from reme_ai import ReMeApp
|
||||
|
||||
async def main():
|
||||
async with ReMeApp(
|
||||
"llm.default.model_name=qwen3-30b-a3b-thinking-2507",
|
||||
"embedding_model.default.model_name=text-embedding-v4",
|
||||
"vector_store.default.backend=memory"
|
||||
) as app:
|
||||
# Memory Integration: Learn from user interactions
|
||||
result = await app.async_execute(
|
||||
name="summary_personal_memory",
|
||||
workspace_id="task_workspace",
|
||||
trajectories=[
|
||||
{
|
||||
"messages": [
|
||||
{"role": "user", "content": "I like to drink coffee while working in the morning"},
|
||||
{"role": "assistant",
|
||||
"content": "I understand, you prefer to start your workday with coffee to stay energized"}
|
||||
]
|
||||
}
|
||||
]
|
||||
)
|
||||
print(result)
|
||||
|
||||
# Memory Retrieval: Get personal memory fragments
|
||||
result = await app.async_execute(
|
||||
name="retrieve_personal_memory",
|
||||
workspace_id="task_workspace",
|
||||
query="What are the user's work habits?",
|
||||
top_k=5
|
||||
)
|
||||
print(result)
|
||||
|
||||
if __name__ == "__main__":
|
||||
asyncio.run(main())
|
||||
```
|
||||
````
|
||||
|
||||
|
||||
```{code-cell}
|
||||
# Memory Integration: Learn from user interactions
|
||||
response = requests.post("http://localhost:8002/summary_personal_memory", json={
|
||||
|
|
|
|||
80
mkdocs.yml
80
mkdocs.yml
|
|
@ -1,80 +0,0 @@
|
|||
site_name: ReMe
|
||||
site_url: https://modelscope.github.io/ReMe/
|
||||
site_description: "Memory Management Framework for Agents"
|
||||
repo_url: https://github.com/modelscope/ReMe
|
||||
repo_name: modelscope/ReMe
|
||||
theme:
|
||||
name: shadcn
|
||||
image: figure/reme_logo.png
|
||||
show_stargazers: true
|
||||
|
||||
|
||||
nav:
|
||||
- Welcome: index.md
|
||||
|
||||
- Library:
|
||||
- Library Home: library/library.md
|
||||
- Use Library: library/use_library.md
|
||||
|
||||
- Personal Memory:
|
||||
- Overview: personal_memory/personal_memory.md
|
||||
- Retrieve Ops: personal_memory/personal_retrieve_ops.md
|
||||
- Summary Ops: personal_memory/personal_summary_ops.md
|
||||
|
||||
- Task Memory:
|
||||
- Overview: task_memory/task_memory.md
|
||||
- Retrieve Ops: task_memory/task_retrieve_ops.md
|
||||
- Summary Ops: task_memory/task_summary_ops.md
|
||||
|
||||
- Tool Memory:
|
||||
- Overview: tool_memory/tool_memory.md
|
||||
- Retrieve Ops: tool_memory/tool_retrieve_ops.md
|
||||
- Summary Ops: tool_memory/tool_summary_ops.md
|
||||
- Benchmark: tool_memory/tool_bench.md
|
||||
|
||||
- SOP Memory:
|
||||
- Making SOP Memories: sop_memory/making_sop_memories.md
|
||||
|
||||
- Extensions:
|
||||
- MCP: mcp_quick_start.md
|
||||
- Vector Store: vector_store_api_guide.md
|
||||
|
||||
- Experimental Tutorials:
|
||||
- Overview: cookbook/experiment_overview.md
|
||||
- AppWorld: cookbook/appworld/quickstart.md
|
||||
- BFCL: cookbook/bfcl/quickstart.md
|
||||
- FrozenLake: cookbook/frozenlake/quickstart.md
|
||||
|
||||
- Future Work:
|
||||
- future_work.md
|
||||
|
||||
- Contribution Guide: contribution.md
|
||||
|
||||
plugins:
|
||||
- search
|
||||
- excalidraw
|
||||
|
||||
markdown_extensions:
|
||||
admonition:
|
||||
codehilite:
|
||||
fenced_code:
|
||||
footnotes:
|
||||
extra:
|
||||
pymdownx.blocks.details:
|
||||
pymdownx.tabbed:
|
||||
pymdownx.blocks.tab:
|
||||
combine_header_slug: true
|
||||
separator: ___
|
||||
pymdownx.progressbar:
|
||||
pymdownx.snippets:
|
||||
pymdownx.arithmatex:
|
||||
generic: true
|
||||
shadcn.extensions.echarts.alpha:
|
||||
shadcn.extensions.codexec:
|
||||
shadcn.extensions.iconify:
|
||||
|
||||
|
||||
# pip install mkdocs-shadcn
|
||||
# mkdocs build
|
||||
# mkdocs serve
|
||||
# mkdocs gh-deploy --force
|
||||
Loading…
Add table
Reference in a new issue