Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/ai/AkamaiAgentCR.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ describe('AkamaiAgentCR', () => {
expect(agentCR.metadata.namespace).toBe('team-team-123')
expect(agentCR.metadata.labels?.['apl.io/teamId']).toBe('team-123')
expect(agentCR.spec.foundationModel).toBe('gpt-4')
expect(agentCR.spec.systemPrompt).toBe('You are a helpful assistant')
expect(agentCR.spec.agentInstructions).toBe('You are a helpful assistant')
expect(agentCR.spec.knowledgeBase).toBe('test-kb')
})

Expand Down Expand Up @@ -202,7 +202,7 @@ describe('AkamaiAgentCR', () => {
apiVersion: 'akamai.com/v1',
kind: 'Agent',
metadata: { name: 'existing-agent', namespace: 'team-456' },
spec: { foundationModel: 'gpt-3.5', systemPrompt: 'Test prompt' },
spec: { foundationModel: 'gpt-3.5', agentInstructions: 'Test prompt' },
}

const result = AkamaiAgentCR.fromCR(crObject)
Expand Down
6 changes: 3 additions & 3 deletions src/ai/AkamaiAgentCR.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export class AkamaiAgentCR {
}
public spec: {
foundationModel: string
systemPrompt: string
agentInstructions: string
knowledgeBase?: string
}

Expand All @@ -37,7 +37,7 @@ export class AkamaiAgentCR {
}
this.spec = {
foundationModel: request.spec.foundationModel,
systemPrompt: request.spec.agentInstructions,
agentInstructions: request.spec.agentInstructions,
knowledgeBase: request.spec.knowledgeBase,
}
}
Expand Down Expand Up @@ -65,7 +65,7 @@ export class AkamaiAgentCR {
},
spec: {
foundationModel: this.spec.foundationModel,
agentInstructions: this.spec.systemPrompt,
agentInstructions: this.spec.agentInstructions,
knowledgeBase: this.spec.knowledgeBase || '',
},
status: {
Expand Down
Loading