spring-projects / spring-projects/spring-ai

AssistantMessage doesn't support 'name' property

Open
#3,737 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

status: to-discuss
Dominant language
Java
Stars
9.5k
Forks
2.9k
Avg merge
1d 7h
Merged PRs (30d)
6

Description

I found that AssistantMessage doesn't contain name property when I want to build a multi-agent system.
This field allows the model to distinguish the name of the assistant, making it easier for building multi-agent systems to share global context.

Expected Behavior
may be we can add a name property to constructor like this:

`public AssistantMessage(String content, String name) {
            xxx
}`

and post it to provider api.

Current Behavior
no property
Context
deepseek has this property, like https://api-docs.deepseek.com/api/create-chat-completion, and so does open ai.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the AssistantMessage definition and its constructor, then trace how assistant messages are mapped into provider API requests. Compare the DeepSeek and OpenAI message formats referenced in the issue. Done means the assistant name is represented and forwarded through the relevant provider APIs, with existing behavior preserved.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, spring
Domain
ai, api
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.