Skip to content

Commit 704a0eb

Browse files
Remove kind parameter from Agent examples to match Python SDK
- Remove explicit kind: 'Agent' from all examples and README - Agent constructor defaults kind to 'Agent' automatically - Matches Python SDK pattern where Agent() doesn't require kind parameter - All builds still passing
1 parent bfdb3ef commit 704a0eb

File tree

3 files changed

+4
-8
lines changed

3 files changed

+4
-8
lines changed

README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ npm install @openhands/agent-server-typescript-client
2424
import { Conversation, Agent, Workspace } from '@openhands/agent-server-typescript-client';
2525

2626
const agent = new Agent({
27-
kind: 'CodeActAgent',
2827
llm: {
2928
model: 'gpt-4',
3029
api_key: 'your-openai-api-key'

example/src/components/ConversationManager.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,6 @@ export const ConversationManager: React.FC = () => {
193193
try {
194194
// Create a simple agent configuration
195195
const agent = new Agent({
196-
kind: 'Agent',
197196
llm: {
198197
model: settings.modelName,
199198
api_key: settings.apiKey || ''

examples/basic-usage.ts

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,12 @@ import { Conversation, Agent, Workspace, AgentExecutionStatus } from '../src/ind
66

77
async function main() {
88
// Define the agent configuration
9-
const agent: Agent = {
10-
kind: 'CodeActAgent',
9+
const agent = new Agent({
1110
llm: {
1211
model: 'gpt-4',
1312
api_key: process.env.OPENAI_API_KEY || 'your-openai-api-key',
1413
},
15-
};
14+
});
1615

1716
try {
1817
// Create a remote workspace
@@ -85,13 +84,12 @@ async function main() {
8584

8685
// Example of loading an existing conversation
8786
async function loadExistingConversation() {
88-
const agent: Agent = {
89-
kind: 'CodeActAgent',
87+
const agent = new Agent({
9088
llm: {
9189
model: 'gpt-4',
9290
api_key: process.env.OPENAI_API_KEY || 'your-openai-api-key',
9391
},
94-
};
92+
});
9593

9694
try {
9795
// Create a remote workspace for the existing conversation

0 commit comments

Comments
 (0)