chatwitheino/cmd/ch04/main.go中没有将工具调用上下文存入到session中
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 65/100
Research direction
Start with quickstart/chatwitheino/cmd/ch04/main.go and inspect how userMsg, assistantMsg, and tool-call results are appended to session. Reproduce a multi-turn conversation that uses a tool, then verify that the session retains the tool-call context and returned result so a later request can refer to it.
Written by the indexing model from the issue text.
Description
https://github.com/cloudwego/eino-examples/blob/main/quickstart/chatwitheino/cmd/ch04/main.go
示例中似乎只把userMsg、assistantMsg(最终文本)存入到了session中,丢失了工具调用的上下文——不知道之前调用过哪些工具、工具返回了什么结果。对于需要参考之前工具调用结果的多轮对话场景(比如"基于之前读的那个文件再做些修改"),模型会表现得"失忆"。
userMsg := msgops.NewUser[M](line)
if err := session.Append(userMsg); err != nil {
_, _ = fmt.Fprintln(os.Stderr, err)
os.Exit(1)
}
assistantMsg := msgops.NewAssistant[M](result.AssistantText, nil)
if err := session.Append(assistantMsg); err != nil {
_, _ = fmt.Fprintln(os.Stderr, err)
os.Exit(1)
}
- Dominant language
- Go
- Stars
- 806
- Forks
- 274
- Avg merge
- 13h 34m
- Merged PRs (30d)
- 2
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from cloudwego/eino-examples
-
Difficulty 4/5 1-2 days Newbie friendliness 20/100
cloudwego/eino-examples#264 ·
-
quickstart/chatwitheino: agenticopenai/agenticark pinned to v0.2.0-beta.1 breaks reasoning models (reasoning_text not handled)Possibly taken @yushuosun claimed this 4 days ago. Open
Difficulty 3/5 1-2 days Newbie friendliness 72/100
cloudwego/eino-examples#258 ·
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
cloudwego/eino-examples#242 · 1 comment ·
All issues in cloudwego/eino-examples
Similar issues
-
gui: a narrow window's gateway key row with a line under it wraps its faded badges onto blank linesOpen
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
contribution macOS 主机
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Lee-xeo/Claude-Cage#1386 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
prime-radiant-inc/evener#8264 ·
Maintainers usually reply within 1 day
-
Add a list commandOpenbackup-operator
Difficulty 2/5 1-3 hours Newbie friendliness 63/100
platform-mesh/platform-mesh#819 ·
Maintainers usually reply within 1 day