Skip to content

Commit 311c22b

Browse files
authored
feat: add Python A2A agent example with Nacos registration (#416)
1 parent a87671a commit 311c22b

11 files changed

Lines changed: 1657 additions & 0 deletions

File tree

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
#
2+
# Copyright 2024-2026 the original author or authors.
3+
#
4+
# Licensed under the Apache License, Version 2.0 (the "License");
5+
# you may not use this file except in compliance with the License.
6+
# You may obtain a copy of the License at
7+
#
8+
# https://www.apache.org/licenses/LICENSE-2.0
9+
#
10+
# Unless required by applicable law or agreed to in writing, software
11+
# distributed under the License is distributed on an "AS IS" BASIS,
12+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
# See the License for the specific language governing permissions and
14+
# limitations under the License.
15+
#
16+
17+
# Python A2A Agent Configuration Example
18+
# Copy this file to .env and fill in your values
19+
20+
# Agent Configuration
21+
AGENT_NAME=python-translator-agent
22+
AGENT_HOST=127.0.0.1
23+
AGENT_PORT=8000
24+
25+
# Nacos Configuration
26+
NACOS_SERVER_ADDR=127.0.0.1:8848
27+
NACOS_NAMESPACE=public
28+
NACOS_USERNAME=nacos
29+
NACOS_PASSWORD=nacos
30+
NACOS_ENABLED=true
31+
32+
# LLM Configuration (DashScope / OpenAI compatible)
33+
DASHSCOPE_API_KEY=your-dashscope-api-key
34+
OPENAI_BASE_URL=https://dashscope.aliyuncs.com/compatible-mode/v1
35+
OPENAI_MODEL=qwen-plus
36+
37+
# Or use standard OpenAI
38+
# OPENAI_API_KEY=your-openai-api-key
39+
# OPENAI_BASE_URL=https://api.openai.com/v1
40+
# OPENAI_MODEL=gpt-4

0 commit comments

Comments
 (0)