Keep - Go SDK

Keep type definition

The Go SDK and docs are currently in beta. Report issues on GitHub.

Supported Types

AnthropicThinkingTurns

1keep := components.CreateKeepAnthropicThinkingTurns(components.AnthropicThinkingTurns{/* values here */})

KeepAll

1keep := components.CreateKeepKeepAll(components.KeepAll{/* values here */})

KeepEnum

1keep := components.CreateKeepKeepEnum(components.KeepEnum{/* values here */})

Union Discrimination

Use the Type field to determine which variant is active, then access the corresponding field:

1switch keep.Type {
2 case components.KeepUnionTypeAnthropicThinkingTurns:
3 // keep.AnthropicThinkingTurns is populated
4 case components.KeepUnionTypeKeepAll:
5 // keep.KeepAll is populated
6 case components.KeepUnionTypeKeepEnum:
7 // keep.KeepEnum is populated
8}