Skip to content

armgit / ax

Public Imported from GitHub
0

Agent Executor (AX) is Google's open agentic orchestration runtime

Go

Rebase from mirror branch (#1)

Jaana Dogan678ddf011a39
diff --git a/README.md b/README.md
index bcbfbf6..acfacad 100644
--- a/README.md
+++ b/README.md
@@ -17,19 +17,12 @@ Built-in consistency and resumability features:
```
┌────────────────────────┐
-│ [Controller] │
-│ - Session Manager │
-│ - Event Log │
-│ - Loop Executor │
-│ - Agent Registry │
-└──────┬──────────┬──────┘
- │ │
- (in-process) (gRPC stream)
- │ │
- ┌───────┐ ┌───────┐
- │ Local │ │Remote │
- │ Agent │ │ Agent │
- └───────┘ └───────┘
+│ [Controller] │ ┌──────────────┐
+│ - Session Manager │--(in process)---| local agent |
+│ - Event Log │ └──────────────┘
+│ - Loop Executor │ ┌──────────────┐
+│ - Agent Registry │--(gRPC stream)--| remote agent |
+└────────────────────────┘ └──────────────┘
```
## Installation
@@ -89,11 +82,11 @@ gar register \
# Trigger a session - gar will trigger the remote agent via Process RPC
gar trigger \
- --session-id session123 \
+ --session session123 \
--input "Hello remote agent"
# Inspect session details
-gar inspect --session-id session123
+gar inspect --session session123
```
## Usage
@@ -107,7 +100,7 @@ The `gar` command provides several subcommands:
```bash
gar trigger \
--input <text> \
- [--session-id <id>] \
+ [--session <id>] \
[--checkpoint <uuid>] \
[--server <address>]
```
@@ -116,7 +109,7 @@ Triggers a new agentic loop session or automatically resumes an existing one. If
Options:
- `--input`: Input message to send to agents (required)
-- `--session-id`: Unique session identifier (optional, generates UUID if not provided, or resumes if exists)
+- `--session`: Unique session identifier (optional, generates UUID if not provided, or resumes if exists)
- `--checkpoint`: Resume from specific checkpoint (empty for latest)
- `--server`: gRPC controller server address (default: "localhost:8494")
@@ -127,10 +120,10 @@ Options:
gar trigger --input "Hello agent"
# Resume an existing session with new input
-gar trigger --session-id abc123 --input "Continue processing"
+gar trigger --session abc123 --input "Continue processing"
# Resume from a specific checkpoint (useful for undoing mistakes or exploring alternatives)
-gar trigger --session-id abc123 \
+gar trigger --session abc123 \
--checkpoint "550e8400-e29b-41d4-a716-446655440000" \
--input "Try a different approach"
```
@@ -138,11 +131,11 @@ gar trigger --session-id abc123 \
#### Inspect a Session
```bash
-gar inspect --session-id <id> [--server <address>]
+gar inspect --session <id> [--server <address>]
```
Options:
-- `--session-id`: Session identifier to inspect (required)
+- `--session`: Session identifier to inspect (required)
- `--server`: gRPC controller server address (default: "localhost:8494")
#### Register a Remote Agent
@@ -209,16 +202,16 @@ gar serve --config my-config.yaml
### Checkpoints
-Checkpoints provide a mechanism to save and resume session state at specific points. Every content event (both `CONTENT_IN` and `CONTENT_OUT`) automatically creates a checkpoint with a unique UUID.
+Checkpoints provide a mechanism to save and resume session state at specific points. Every content event (`CONTENT`) can create a checkpoint with a unique UUID.
**Usage Examples:**
```bash
# Inspect a session to see available checkpoints
-gar inspect --session-id session123
+gar inspect --session session123
# Resume from a specific checkpoint
-gar trigger --session-id session123 \
+gar trigger --session session123 \
--checkpoint "550e8400-e29b-41d4-a716-446655440000" \
--input "Try different approach"
```
@@ -229,15 +222,14 @@ gar trigger --session-id session123 \
Event logs use JSON Lines format (one JSON object per line). Each entry includes the session ID, a monotonic sequence number, and checkpoint ID (for content events) for traceability:
```json
-{"session_id": "session123", "timestamp": "2026-01-02T10:30:00Z", "seq": 0, "type": "CONTENT_IN", "checkpoint_id": "550e8400-e29b-41d4-a716-446655440000", "data": {...}}
-{"session_id": "session123", "timestamp": "2026-01-02T10:30:01Z", "seq": 1, "type": "CONTENT_OUT", "checkpoint_id": "6ba7b810-9dad-11d1-80b4-00c04fd430c8", "data": {...}}
-{"session_id": "session123", "timestamp": "2026-01-02T10:30:02Z", "seq": 2, "type": "STATE", "data": {...}}
+{"type": "CONTENT", "timestamp": "2026-01-02T10:30:00Z", "seq": 0, "checkpoint_id": "550e8400-e29b-41d4-a716-446655440000", "data": {...}}
+{"type": "CONTENT", "timestamp": "2026-01-02T10:30:01Z", "seq": 1,"checkpoint_id": "6ba7b810-9dad-11d1-80b4-00c04fd430c8", "data": {...}}
+{"type": "SESSION_FAILED", "timestamp": "2026-01-02T10:30:02Z", "seq": 2, "data": {...}}
```
**Event Types:**
-- `CONTENT_IN`: Incoming content from user or external source (includes `checkpoint_id`)
-- `CONTENT_OUT`: Outgoing content from agents (includes `checkpoint_id`)
-- `STATE`: Session state changes, e.g. running, completed, failed.
+- `CONTENT`: Incoming or outgoing content from user or agent (optionally includes `checkpoint_id`).
+- `SESSION_FAILED`: Session state has failed and session is not resumable.
## Building Custom Agents
@@ -388,7 +380,7 @@ gar register \
# Trigger a session
gar trigger \
- --session-id session123 \
+ --session session123 \
--input "Hello, I heard that there is an agent that can help with processing this text!"
```
diff --git a/cmd/gar/inspect.go b/cmd/gar/inspect.go
index 8068f05..76f7dae 100644
--- a/cmd/gar/inspect.go
+++ b/cmd/gar/inspect.go
@@ -36,9 +36,9 @@ var inspectCmd = &cobra.Command{
}
func init() {
- inspectCmd.Flags().StringVar(&inspectSessionID, "session-id", "", "Session ID (required)")
+ inspectCmd.Flags().StringVar(&inspectSessionID, "session", "", "Session ID (required)")
inspectCmd.Flags().StringVar(&inspectServerAddr, "server", "localhost:8494", "gRPC controller server address (default: localhost:8494)")
- inspectCmd.MarkFlagRequired("session-id")
+ inspectCmd.MarkFlagRequired("session")
}
func runInspect(cmd *cobra.Command, args []string) error {
@@ -67,7 +67,7 @@ func runInspect(cmd *cobra.Command, args []string) error {
fmt.Printf(" State: %s\n", session.State)
fmt.Printf(" Created At: %s\n", session.CreatedAt.AsTime().Format(time.RFC3339))
fmt.Printf(" Updated At: %s\n", session.UpdatedAt.AsTime().Format(time.RFC3339))
- fmt.Printf(" Checkpoints: %d\n", session.CheckpointCount)
+ fmt.Printf(" Checkpoints: %v\n", session.CheckpointIds)
fmt.Printf(" Active Agents: %v\n", session.ActiveAgents)
return nil
diff --git a/cmd/gar/register.go b/cmd/gar/register.go
index 600c70f..d874ab7 100644
--- a/cmd/gar/register.go
+++ b/cmd/gar/register.go
@@ -51,7 +51,7 @@ func init() {
func runRegister(cmd *cobra.Command, args []string) error {
ctx := context.Background()
- conn, err := connect(inspectServerAddr)
+ conn, err := connect(registerServerAddr)
if err != nil {
return err
}
diff --git a/cmd/gar/serve.go b/cmd/gar/serve.go
index 3eb82ec..5e65412 100644
--- a/cmd/gar/serve.go
+++ b/cmd/gar/serve.go
@@ -17,6 +17,7 @@ package main
import (
"context"
"fmt"
+ "log"
"os"
"os/signal"
"syscall"
@@ -58,7 +59,6 @@ func runServe(cmd *cobra.Command, args []string) error {
return fmt.Errorf("invalid configuration: %w", err)
}
- fmt.Printf("Starting GAR server at %s...\n", cfg.Server.Address)
c, err := newControllerFromConfig(ctx, cfg)
if err != nil {
return fmt.Errorf("error creating controller: %w", err)
@@ -74,11 +74,11 @@ func runServe(cmd *cobra.Command, args []string) error {
go func() {
<-sigChan
- fmt.Println("\nReceived interrupt, shutting down...")
+ log.Println("\nReceived interrupt, shutting down...")
os.Exit(0)
}()
- // Start serving
+ log.Printf("Starting GAR server at %s...\n", cfg.Server.Address)
if err := srv.Serve(cfg.Server.Address); err != nil {
return fmt.Errorf("error serving: %w", err)
}
@@ -117,5 +117,10 @@ func newControllerFromConfig(ctx context.Context, cfg *config.Config) (*controll
}
}
+ agents := c.Registry().List()
+ if len(agents) == 0 {
+ log.Println("WARNING: No agents at startup.")
+ }
+
return c, nil
}
diff --git a/cmd/gar/trigger.go b/cmd/gar/trigger.go
index 64244b9..f197a33 100644
--- a/cmd/gar/trigger.go
+++ b/cmd/gar/trigger.go
@@ -44,7 +44,10 @@ Use --checkpoint to resume from a specific checkpoint.`,
}
func init() {
- triggerCmd.Flags().StringVar(&triggerSessionID, "session-id", "", "Session ID (optional, generates UUID if not provided)")
+ // TODO(jbd): Enable a -headless option that can run
+ // the controller without a gar server.
+
+ triggerCmd.Flags().StringVar(&triggerSessionID, "session", "", "Session ID (optional, generates UUID if not provided)")
triggerCmd.Flags().StringVar(&triggerInput, "input", "", "Input message to send (required)")
triggerCmd.Flags().StringVar(&triggerCheckpoint, "checkpoint", "", "Resume from specific checkpoint UUID (empty for latest)")
triggerCmd.Flags().StringVar(&triggerServerAddr, "server", "localhost:8494", "gRPC controller server address (default: localhost:8494)")
@@ -85,7 +88,7 @@ func runTrigger(cmd *cobra.Command, args []string) error {
cancel()
}()
- conn, err := connect(inspectServerAddr)
+ conn, err := connect(triggerServerAddr)
if err != nil {
return err
}
diff --git a/go.mod b/go.mod
index bf426b2..5d9dcd0 100644
--- a/go.mod
+++ b/go.mod
@@ -5,6 +5,7 @@ go 1.24.0
require (
github.com/google/uuid v1.6.0
github.com/spf13/cobra v1.10.2
+ golang.org/x/sync v0.19.0
google.golang.org/genai v1.43.0
google.golang.org/grpc v1.78.0
google.golang.org/protobuf v1.36.11
diff --git a/internal/controller/controller.go b/internal/controller/controller.go
index 2034ac4..36b5fcd 100644
--- a/internal/controller/controller.go
+++ b/internal/controller/controller.go
@@ -130,15 +130,12 @@ func (d *Controller) TriggerSession(ctx context.Context, sessionID string, input
// Write input content to session
for _, content := range inputs {
- if _, err := sess.WriteContentIn(ctx, content); err != nil {
+ if _, err := sess.WriteContentIn(ctx, "", content); err != nil {
return fmt.Errorf("failed to write input content: %w", err)
}
}
if err := d.loopExecutor.Execute(ctx, sess, handler); err != nil {
- if err := sess.SetState(ctx, proto.State_STATE_FAILED); err != nil {
- return fmt.Errorf("failed to set session state: %w", err)
- }
return fmt.Errorf("loop execution failed: %w", err)
}
return nil
diff --git a/internal/controller/gemini.go b/internal/controller/gemini.go
index 8de3d82..9c2f930 100644
--- a/internal/controller/gemini.go
+++ b/internal/controller/gemini.go
@@ -81,7 +81,7 @@ Guidelines:
}
// Return the plan function
- return func(ctx context.Context, inputs []*proto.Content) (*Task, error) {
+ return func(ctx context.Context, inputs []*proto.Content) ([]*Task, error) {
// Create a context with timeout
ctx, cancel := context.WithTimeout(ctx, config.Timeout)
defer cancel()
@@ -122,10 +122,10 @@ Guidelines:
}
if fc := part.FunctionCall; fc != nil {
- return &Task{
+ return []*Task{{
AgentID: fc.Name,
Inputs: inputs,
- }, nil
+ }}, nil
}
}
return nil, nil
diff --git a/internal/controller/loop.go b/internal/controller/loop.go
index ce1c4ec..2670027 100644
--- a/internal/controller/loop.go
+++ b/internal/controller/loop.go
@@ -20,6 +20,7 @@ import (
"github.com/google/gar/agent"
"github.com/google/gar/proto"
+ "golang.org/x/sync/errgroup"
)
// Task represents a task to be executed by an agent.
@@ -39,7 +40,7 @@ type LoopExecutor struct {
// PlanFunc determines the next agent task to execute.
// It receives the current session state and returns the next task.
-type PlanFunc func(ctx context.Context, inputs []*proto.Content) (*Task, error)
+type PlanFunc func(ctx context.Context, inputs []*proto.Content) ([]*Task, error)
// LoopConfig configures the loop executor.
type LoopConfig struct {
@@ -97,26 +98,23 @@ func (e *LoopExecutor) runLoop(ctx context.Context, session *Session, handler ag
default:
}
- task, err := e.planFunc(ctx, session.History())
+ tasks, err := e.planFunc(ctx, session.History())
if err != nil {
return fmt.Errorf("planning failed: %w", err)
}
- if task == nil {
+ if len(tasks) == 0 {
// No more tasks to execute; loop is complete.
return nil
}
- taskOutputHandler := func(content *proto.Content) error {
- if _, err := session.WriteContentOut(ctx, content); err != nil {
- return fmt.Errorf("failed to write output content: %w", err)
- }
- if err := handler(content); err != nil {
- return fmt.Errorf("output handler error: %w", err)
- }
- return nil
+ g, ctx := errgroup.WithContext(ctx)
+ for _, task := range tasks {
+ g.Go(func() error {
+ return e.runTask(ctx, session, task, handler)
+ })
}
- if err := e.executeTask(ctx, session.ID(), task, taskOutputHandler); err != nil {
+ if err := g.Wait(); err != nil {
return err
}
@@ -127,6 +125,20 @@ func (e *LoopExecutor) runLoop(ctx context.Context, session *Session, handler ag
return fmt.Errorf("max steps per trigger (%d) reached", e.maxSteps)
}
+func (e *LoopExecutor) runTask(ctx context.Context, session *Session, task *Task, handler agent.OutputHandler) error {
+ // TODO(jbd): Log task start and task end to allow resuming dangling tasks.
+ taskOutputHandler := func(content *proto.Content) error {
+ if _, err := session.WriteContentOut(ctx, task.AgentID, content); err != nil {
+ return fmt.Errorf("failed to write output content: %w", err)
+ }
+ if err := handler(content); err != nil {
+ return fmt.Errorf("output handler error: %w", err)
+ }
+ return nil
+ }
+ return e.executeTask(ctx, session.ID(), task, taskOutputHandler)
+}
+
// executeTask sends input to an agent and collects output.
func (e *LoopExecutor) executeTask(ctx context.Context, sessionID string, task *Task, handler agent.OutputHandler) error {
// Get the agent from registry
diff --git a/internal/controller/session.go b/internal/controller/session.go
index cb2fa28..739a8bc 100644
--- a/internal/controller/session.go
+++ b/internal/controller/session.go
@@ -112,7 +112,7 @@ func (sm *SessionManager) LoadSessionFromCheckpoint(ctx context.Context, session
}
defer replayLog.Close()
- entries, state, err := replayLog.RetrieveEntries(ctx)
+ entries, state, err := replayLog.Load(ctx, checkpointID)
if err != nil {
return nil, fmt.Errorf("failed to get event log entries: %w", err)
}
@@ -129,18 +129,10 @@ func (sm *SessionManager) LoadSessionFromCheckpoint(ctx context.Context, session
updatedAt: time.Now(),
}
- targetReached := false
- checkpointFound := false
-
// Replay entries to rebuild state
for _, entry := range entries {
- // If we've reached the target checkpoint, stop processing
- if targetReached {
- break
- }
-
switch entry.Type {
- case eventlog.EventTypeContentIn, eventlog.EventTypeContentOut:
+ case eventlog.EventTypeContent:
content := &proto.Content{
Role: getStringFromData(entry.Data, "role"),
Type: getStringFromData(entry.Data, "type"),
@@ -152,23 +144,12 @@ func (sm *SessionManager) LoadSessionFromCheckpoint(ctx context.Context, session
// Track checkpoint ID if present
if entry.CheckpointID != "" {
session.checkpointIDs = append(session.checkpointIDs, entry.CheckpointID)
-
- // Check if this is the target checkpoint
- if checkpointID != "" && entry.CheckpointID == checkpointID {
- targetReached = true
- checkpointFound = true
- }
}
}
session.updatedAt = entry.Timestamp
}
- // Validate checkpoint ID if provided
- if checkpointID != "" && !checkpointFound {
- return nil, fmt.Errorf("checkpoint ID %s not found in session", checkpointID)
- }
-
// Reopen event log for appending using the factory
el, err := sm.eventLogFactory(sessionID)
if err != nil {
@@ -227,7 +208,7 @@ func (sm *SessionManager) CloseAll() {
// WriteContentIn appends an incoming content message to the session.
// Creates a checkpoint only if checkpoint_id is provided in the content.
-func (s *Session) WriteContentIn(ctx context.Context, content *proto.Content) (string, error) {
+func (s *Session) WriteContentIn(ctx context.Context, agentID string, content *proto.Content) (string, error) {
s.mu.Lock()
defer s.mu.Unlock()
@@ -243,7 +224,7 @@ func (s *Session) WriteContentIn(ctx context.Context, content *proto.Content) (s
}
}
- if err := s.eventLog.AppendContent(ctx, eventlog.EventTypeContentIn, checkpointID, content); err != nil {
+ if err := s.eventLog.AppendContent(ctx, checkpointID, agentID, content); err != nil {
return "", err
}
@@ -256,14 +237,14 @@ func (s *Session) WriteContentIn(ctx context.Context, content *proto.Content) (s
}
// WriteContentOut appends an outgoing content message to the session with a new checkpoint.
-func (s *Session) WriteContentOut(ctx context.Context, content *proto.Content) (string, error) {
+func (s *Session) WriteContentOut(ctx context.Context, agentID string, content *proto.Content) (string, error) {
s.mu.Lock()
defer s.mu.Unlock()
// Generate a new checkpoint UUID
checkpointID := uuid.New().String()
- if err := s.eventLog.AppendContent(ctx, eventlog.EventTypeContentOut, checkpointID, content); err != nil {
+ if err := s.eventLog.AppendContent(ctx, checkpointID, agentID, content); err != nil {
return "", err
}
diff --git a/internal/eventlog/eventlog.go b/internal/eventlog/eventlog.go
index 495d0f4..f807235 100644
--- a/internal/eventlog/eventlog.go
+++ b/internal/eventlog/eventlog.go
@@ -27,19 +27,19 @@ import (
type EventType string
const (
- EventTypeState EventType = "STATE"
- EventTypeContentIn EventType = "CONTENT_IN"
- EventTypeContentOut EventType = "CONTENT_OUT"
+ EventTypeContent EventType = "CONTENT"
+ EventTypeSessionFailed EventType = "SESSION_FAILED" // cannot resume
// TODO(jbd): Add EventTypeCompaction.
+ // TODO(jbd): Events for agent call lifecycle.
)
// Entry represents a single entry in the event log.
type Entry struct {
- SessionID string `json:"session_id"`
+ Type EventType `json:"type"`
CheckpointID string `json:"checkpoint_id,omitempty"` // UUID for checkpoint tracking
+ AgentID string `json:"agent_id,omitempty"` // Associated agent ID, could be empty
Sequence int64 `json:"seq"` // Monotonic sequence number
Timestamp time.Time `json:"timestamp"`
- Type EventType `json:"type"`
Data map[string]any `json:"data"`
}
@@ -47,13 +47,14 @@ type Entry struct {
// It provides methods for appending events, reading entries, and managing the log lifecycle.
type EventLog interface {
// AppendContent appends a content message to the event log with a checkpoint UUID.
- AppendContent(ctx context.Context, t EventType, checkpointID string, content *proto.Content) error
+ AppendContent(ctx context.Context, checkpointID string, agentID string, content *proto.Content) error
// AppendState appends a state to the event log.
AppendState(ctx context.Context, s proto.State) error
- // RetrieveEntries returns all entries from the event log in order.
- RetrieveEntries(ctx context.Context) ([]Entry, proto.State, error)
+ // Load returns all entries from the event log in order.
+ // If checkpointID is provided, returns entries up to and including that checkpoint.
+ Load(ctx context.Context, checkpointID string) ([]Entry, proto.State, error)
// Close closes the event log and releases any resources.
Close() error
diff --git a/internal/eventlog/file.go b/internal/eventlog/file.go
index 4c2c858..03beff4 100644
--- a/internal/eventlog/file.go
+++ b/internal/eventlog/file.go
@@ -18,6 +18,7 @@ import (
"bufio"
"context"
"encoding/json"
+ "errors"
"fmt"
"os"
"path/filepath"
@@ -103,18 +104,18 @@ func NewFileConfig(config FileConfig) (EventLog, error) {
return NewFileEventLog(config)
}
-// Append writes an entry to the event log.
+// append writes an entry to the event log.
// Entries are written in JSON Lines format with atomic appends.
-func (e *FileEventLog) Append(entryType EventType, checkpointID string, data map[string]any) error {
+func (e *FileEventLog) append(checkpointID string, agentID string, entryType EventType, data map[string]any) error {
e.mu.Lock()
defer e.mu.Unlock()
entry := Entry{
- SessionID: e.sessionID,
Timestamp: time.Now(),
Sequence: e.sequence,
Type: entryType,
CheckpointID: checkpointID,
+ AgentID: agentID,
Data: data,
}
@@ -143,21 +144,22 @@ func (e *FileEventLog) Append(entryType EventType, checkpointID string, data map
}
// AppendContent writes a content message to the event log with a checkpoint UUID.
-func (e *FileEventLog) AppendContent(ctx context.Context, direction EventType, checkpointID string, content *proto.Content) error {
+func (e *FileEventLog) AppendContent(ctx context.Context, checkpointID string, agentID string, content *proto.Content) error {
data := map[string]any{
"role": content.Role,
"type": content.Type,
"mimetype": content.Mimetype,
"data": content.Data,
}
- return e.Append(direction, checkpointID, data)
+ return e.append(checkpointID, agentID, EventTypeContent, data)
}
func (e *FileEventLog) AppendState(ctx context.Context, state proto.State) error {
- data := map[string]any{
- "state": state,
+ switch state {
+ case proto.State_STATE_FAILED:
+ return e.append("", "", EventTypeSessionFailed, nil)
}
- return e.Append(EventTypeState, "", data)
+ return errors.New("only COMPLETED and FAILED states are supported")
}
// Close closes the event log file.
@@ -185,9 +187,10 @@ func (e *FileEventLog) SessionID() string {
return e.sessionID
}
-// RetrieveEntries reads and returns all entries from the event log file.
+// Load reads and returns all entries from the event log file.
+// If checkpointID is provided, returns entries up to and including that checkpoint.
// Returns entries in order.
-func (e *FileEventLog) RetrieveEntries(ctx context.Context) ([]Entry, proto.State, error) {
+func (e *FileEventLog) Load(ctx context.Context, checkpointID string) ([]Entry, proto.State, error) {
e.mu.Lock()
defer e.mu.Unlock()
@@ -215,6 +218,8 @@ func (e *FileEventLog) RetrieveEntries(ctx context.Context) ([]Entry, proto.Stat
lineNum := 0
var expectedSequence int64 = 0
+ checkpointFound := false
+
for scanner.Scan() {
lineNum++
line := scanner.Bytes()
@@ -230,17 +235,23 @@ func (e *FileEventLog) RetrieveEntries(ctx context.Context) ([]Entry, proto.Stat
}
expectedSequence++
- if entry.Type == EventTypeState {
- if s, ok := entry.Data["state"].(proto.State); ok {
- state = s
- }
- }
entries = append(entries, entry)
+
+ // Check if this entry matches the target checkpoint
+ if checkpointID != "" && entry.CheckpointID == checkpointID {
+ checkpointFound = true
+ break
+ }
}
if err := scanner.Err(); err != nil {
return nil, 0, fmt.Errorf("error reading event log file: %w", err)
}
+ // Validate checkpoint was found if specified
+ if checkpointID != "" && !checkpointFound {
+ return nil, 0, fmt.Errorf("checkpoint ID %s not found in event log", checkpointID)
+ }
+
return entries, state, nil
}
diff --git a/internal/server/server.go b/internal/server/server.go
index f9d070b..5501d7b 100644
--- a/internal/server/server.go
+++ b/internal/server/server.go
@@ -91,11 +91,11 @@ func (s *Server) GetSession(ctx context.Context, req *proto.GetSessionRequest) (
return &proto.GetSessionResponse{
Session: &proto.SessionInfo{
- State: session.State(),
- ActiveAgents: session.ActiveAgents(),
- CreatedAt: timestamppb.New(session.CreatedAt()),
- UpdatedAt: timestamppb.New(session.UpdatedAt()),
- CheckpointCount: int32(len(session.CheckpointIDs())),
+ State: session.State(),
+ ActiveAgents: session.ActiveAgents(),
+ CreatedAt: timestamppb.New(session.CreatedAt()),
+ UpdatedAt: timestamppb.New(session.UpdatedAt()),
+ CheckpointIds: session.CheckpointIDs(),
},
}, nil
}
diff --git a/proto/gar.pb.go b/proto/gar.pb.go
index cd325fd..ce5dfaa 100644
--- a/proto/gar.pb.go
+++ b/proto/gar.pb.go
@@ -14,8 +14,8 @@
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
-// protoc-gen-go v1.35.1
-// protoc v5.28.2
+// protoc-gen-go v1.36.11
+// protoc v3.21.9
// source: proto/gar.proto
package proto
@@ -26,6 +26,7 @@ import (
timestamppb "google.golang.org/protobuf/types/known/timestamppb"
reflect "reflect"
sync "sync"
+ unsafe "unsafe"
)
const (
@@ -90,15 +91,14 @@ func (State) EnumDescriptor() ([]byte, []int) {
// Content represents a message with role, type, mimetype, and data fields
type Content struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ CheckpointId string `protobuf:"bytes,1,opt,name=checkpoint_id,json=checkpointId,proto3" json:"checkpoint_id,omitempty"` // Optional: Checkpoint ID for this content
+ Role string `protobuf:"bytes,2,opt,name=role,proto3" json:"role,omitempty"` // The role of the content (e.g., "user", "assistant", "system")
+ Type string `protobuf:"bytes,3,opt,name=type,proto3" json:"type,omitempty"` // The type of content (e.g., "text", "image")
+ Mimetype string `protobuf:"bytes,4,opt,name=mimetype,proto3" json:"mimetype,omitempty"` // MIME type of the data (e.g., "text/plain", "image/png")
+ Data string `protobuf:"bytes,5,opt,name=data,proto3" json:"data,omitempty"` // The actual content data
unknownFields protoimpl.UnknownFields
-
- Role string `protobuf:"bytes,1,opt,name=role,proto3" json:"role,omitempty"` // The role of the content (e.g., "user", "assistant", "system")
- Type string `protobuf:"bytes,2,opt,name=type,proto3" json:"type,omitempty"` // The type of content (e.g., "text", "image")
- Mimetype string `protobuf:"bytes,3,opt,name=mimetype,proto3" json:"mimetype,omitempty"` // MIME type of the data (e.g., "text/plain", "image/png")
- Data string `protobuf:"bytes,4,opt,name=data,proto3" json:"data,omitempty"` // The actual content data
- CheckpointId string `protobuf:"bytes,5,opt,name=checkpoint_id,json=checkpointId,proto3" json:"checkpoint_id,omitempty"` // Optional: Checkpoint ID for this content
+ sizeCache protoimpl.SizeCache
}
func (x *Content) Reset() {
@@ -131,6 +131,13 @@ func (*Content) Descriptor() ([]byte, []int) {
return file_proto_gar_proto_rawDescGZIP(), []int{0}
}
+func (x *Content) GetCheckpointId() string {
+ if x != nil {
+ return x.CheckpointId
+ }
+ return ""
+}
+
func (x *Content) GetRole() string {
if x != nil {
return x.Role
@@ -159,18 +166,11 @@ func (x *Content) GetData() string {
return ""
}
-func (x *Content) GetCheckpointId() string {
- if x != nil {
- return x.CheckpointId
- }
- return ""
-}
-
// HealthCheckRequest for agent health checks
type HealthCheckRequest struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *HealthCheckRequest) Reset() {
@@ -205,12 +205,11 @@ func (*HealthCheckRequest) Descriptor() ([]byte, []int) {
// HealthCheckResponse contains agent health status
type HealthCheckResponse struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Healthy bool `protobuf:"varint,1,opt,name=healthy,proto3" json:"healthy,omitempty"`
+ Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"`
unknownFields protoimpl.UnknownFields
-
- Healthy bool `protobuf:"varint,1,opt,name=healthy,proto3" json:"healthy,omitempty"`
- Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *HealthCheckResponse) Reset() {
@@ -259,13 +258,12 @@ func (x *HealthCheckResponse) GetMessage() string {
// TriggerSessionRequest for triggering a new session
type TriggerSessionRequest struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ SessionId string `protobuf:"bytes,1,opt,name=session_id,json=sessionId,proto3" json:"session_id,omitempty"` // Unique session identifier
+ CheckpointId string `protobuf:"bytes,2,opt,name=checkpoint_id,json=checkpointId,proto3" json:"checkpoint_id,omitempty"` // Optional: Resume from specific checkpoint UUID (empty for latest)
+ Inputs []*Content `protobuf:"bytes,3,rep,name=inputs,proto3" json:"inputs,omitempty"` // Input content to process
unknownFields protoimpl.UnknownFields
-
- SessionId string `protobuf:"bytes,1,opt,name=session_id,json=sessionId,proto3" json:"session_id,omitempty"` // Unique session identifier
- CheckpointId string `protobuf:"bytes,2,opt,name=checkpoint_id,json=checkpointId,proto3" json:"checkpoint_id,omitempty"` // Optional: Resume from specific checkpoint UUID (empty for latest)
- Inputs []*Content `protobuf:"bytes,3,rep,name=inputs,proto3" json:"inputs,omitempty"` // Input content to process
+ sizeCache protoimpl.SizeCache
}
func (x *TriggerSessionRequest) Reset() {
@@ -321,13 +319,12 @@ func (x *TriggerSessionRequest) GetInputs() []*Content {
// TriggerSessionResponse contains the result of triggering a session
type TriggerSessionResponse struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ SessionId string `protobuf:"bytes,1,opt,name=session_id,json=sessionId,proto3" json:"session_id,omitempty"` // Session ID (in case it was generated or modified by server)
+ State State `protobuf:"varint,2,opt,name=state,proto3,enum=proto.State" json:"state,omitempty"` // Session state
+ Output *Content `protobuf:"bytes,3,opt,name=output,proto3" json:"output,omitempty"` // Output content
unknownFields protoimpl.UnknownFields
-
- SessionId string `protobuf:"bytes,1,opt,name=session_id,json=sessionId,proto3" json:"session_id,omitempty"` // Session ID (in case it was generated or modified by server)
- State State `protobuf:"varint,2,opt,name=state,proto3,enum=proto.State" json:"state,omitempty"` // Session state
- Output *Content `protobuf:"bytes,3,opt,name=output,proto3" json:"output,omitempty"` // Output content
+ sizeCache protoimpl.SizeCache
}
func (x *TriggerSessionResponse) Reset() {
@@ -383,11 +380,10 @@ func (x *TriggerSessionResponse) GetOutput() *Content {
// GetSessionRequest for retrieving session details
type GetSessionRequest struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ SessionId string `protobuf:"bytes,1,opt,name=session_id,json=sessionId,proto3" json:"session_id,omitempty"`
unknownFields protoimpl.UnknownFields
-
- SessionId string `protobuf:"bytes,1,opt,name=session_id,json=sessionId,proto3" json:"session_id,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *GetSessionRequest) Reset() {
@@ -429,15 +425,14 @@ func (x *GetSessionRequest) GetSessionId() string {
// SessionInfo contains session details
type SessionInfo struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ State State `protobuf:"varint,1,opt,name=state,proto3,enum=proto.State" json:"state,omitempty"`
+ ActiveAgents []string `protobuf:"bytes,2,rep,name=active_agents,json=activeAgents,proto3" json:"active_agents,omitempty"`
+ CheckpointIds []string `protobuf:"bytes,3,rep,name=checkpoint_ids,json=checkpointIds,proto3" json:"checkpoint_ids,omitempty"`
+ CreatedAt *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"` // Session creation time
+ UpdatedAt *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"` // Last update time
unknownFields protoimpl.UnknownFields
-
- State State `protobuf:"varint,1,opt,name=state,proto3,enum=proto.State" json:"state,omitempty"`
- ActiveAgents []string `protobuf:"bytes,2,rep,name=active_agents,json=activeAgents,proto3" json:"active_agents,omitempty"`
- CheckpointCount int32 `protobuf:"varint,3,opt,name=checkpoint_count,json=checkpointCount,proto3" json:"checkpoint_count,omitempty"`
- CreatedAt *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"` // Session creation time
- UpdatedAt *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"` // Last update time
+ sizeCache protoimpl.SizeCache
}
func (x *SessionInfo) Reset() {
@@ -484,11 +479,11 @@ func (x *SessionInfo) GetActiveAgents() []string {
return nil
}
-func (x *SessionInfo) GetCheckpointCount() int32 {
+func (x *SessionInfo) GetCheckpointIds() []string {
if x != nil {
- return x.CheckpointCount
+ return x.CheckpointIds
}
- return 0
+ return nil
}
func (x *SessionInfo) GetCreatedAt() *timestamppb.Timestamp {
@@ -507,11 +502,10 @@ func (x *SessionInfo) GetUpdatedAt() *timestamppb.Timestamp {
// GetSessionResponse contains session information
type GetSessionResponse struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ Session *SessionInfo `protobuf:"bytes,1,opt,name=session,proto3" json:"session,omitempty"`
unknownFields protoimpl.UnknownFields
-
- Session *SessionInfo `protobuf:"bytes,1,opt,name=session,proto3" json:"session,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *GetSessionResponse) Reset() {
@@ -553,15 +547,14 @@ func (x *GetSessionResponse) GetSession() *SessionInfo {
// RegisterAgentRequest for registering an agent
type RegisterAgentRequest struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ AgentId string `protobuf:"bytes,1,opt,name=agent_id,json=agentId,proto3" json:"agent_id,omitempty"`
+ Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` // Human-readable name for the agent
+ Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"` // Description of agent capabilities
+ Address string `protobuf:"bytes,4,opt,name=address,proto3" json:"address,omitempty"` // gRPC address for remote agents
+ Metadata map[string]string `protobuf:"bytes,5,rep,name=metadata,proto3" json:"metadata,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"`
unknownFields protoimpl.UnknownFields
-
- AgentId string `protobuf:"bytes,1,opt,name=agent_id,json=agentId,proto3" json:"agent_id,omitempty"`
- Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` // Human-readable name for the agent
- Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"` // Description of agent capabilities
- Address string `protobuf:"bytes,4,opt,name=address,proto3" json:"address,omitempty"` // gRPC address for remote agents
- Metadata map[string]string `protobuf:"bytes,5,rep,name=metadata,proto3" json:"metadata,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
+ sizeCache protoimpl.SizeCache
}
func (x *RegisterAgentRequest) Reset() {
@@ -631,9 +624,9 @@ func (x *RegisterAgentRequest) GetMetadata() map[string]string {
// RegisterAgentResponse contains registration result
type RegisterAgentResponse struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *RegisterAgentResponse) Reset() {
@@ -668,11 +661,10 @@ func (*RegisterAgentResponse) Descriptor() ([]byte, []int) {
// UnregisterAgentRequest for unregistering an agent
type UnregisterAgentRequest struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
+ AgentId string `protobuf:"bytes,1,opt,name=agent_id,json=agentId,proto3" json:"agent_id,omitempty"`
unknownFields protoimpl.UnknownFields
-
- AgentId string `protobuf:"bytes,1,opt,name=agent_id,json=agentId,proto3" json:"agent_id,omitempty"`
+ sizeCache protoimpl.SizeCache
}
func (x *UnregisterAgentRequest) Reset() {
@@ -714,9 +706,9 @@ func (x *UnregisterAgentRequest) GetAgentId() string {
// UnregisterAgentResponse contains unregistration result
type UnregisterAgentResponse struct {
- state protoimpl.MessageState
- sizeCache protoimpl.SizeCache
+ state protoimpl.MessageState `protogen:"open.v1"`
unknownFields protoimpl.UnknownFields
+ sizeCache protoimpl.SizeCache
}
func (x *UnregisterAgentResponse) Reset() {
@@ -751,135 +743,79 @@ func (*UnregisterAgentResponse) Descriptor() ([]byte, []int) {
var File_proto_gar_proto protoreflect.FileDescriptor
-var file_proto_gar_proto_rawDesc = []byte{
- 0x0a, 0x0f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x61, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74,
- 0x6f, 0x12, 0x05, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65,
- 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74,
- 0x61, 0x6d, 0x70, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x86, 0x01, 0x0a, 0x07, 0x43, 0x6f,
- 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x72, 0x6f, 0x6c, 0x65, 0x18, 0x01, 0x20,
- 0x01, 0x28, 0x09, 0x52, 0x04, 0x72, 0x6f, 0x6c, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70,
- 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x1a, 0x0a,
- 0x08, 0x6d, 0x69, 0x6d, 0x65, 0x74, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52,
- 0x08, 0x6d, 0x69, 0x6d, 0x65, 0x74, 0x79, 0x70, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x61, 0x74,
- 0x61, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x12, 0x23, 0x0a,
- 0x0d, 0x63, 0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x05,
- 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69, 0x6e, 0x74,
- 0x49, 0x64, 0x22, 0x14, 0x0a, 0x12, 0x48, 0x65, 0x61, 0x6c, 0x74, 0x68, 0x43, 0x68, 0x65, 0x63,
- 0x6b, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x49, 0x0a, 0x13, 0x48, 0x65, 0x61, 0x6c,
- 0x74, 0x68, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12,
- 0x18, 0x0a, 0x07, 0x68, 0x65, 0x61, 0x6c, 0x74, 0x68, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08,
- 0x52, 0x07, 0x68, 0x65, 0x61, 0x6c, 0x74, 0x68, 0x79, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x65, 0x73,
- 0x73, 0x61, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x65, 0x73, 0x73,
- 0x61, 0x67, 0x65, 0x22, 0x83, 0x01, 0x0a, 0x15, 0x54, 0x72, 0x69, 0x67, 0x67, 0x65, 0x72, 0x53,
- 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1d, 0x0a,
- 0x0a, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28,
- 0x09, 0x52, 0x09, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x23, 0x0a, 0x0d,
- 0x63, 0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20,
- 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x49,
- 0x64, 0x12, 0x26, 0x0a, 0x06, 0x69, 0x6e, 0x70, 0x75, 0x74, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28,
- 0x0b, 0x32, 0x0e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e,
- 0x74, 0x52, 0x06, 0x69, 0x6e, 0x70, 0x75, 0x74, 0x73, 0x22, 0x83, 0x01, 0x0a, 0x16, 0x54, 0x72,
- 0x69, 0x67, 0x67, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70,
- 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x5f,
- 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f,
- 0x6e, 0x49, 0x64, 0x12, 0x22, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x02, 0x20, 0x01,
- 0x28, 0x0e, 0x32, 0x0c, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x65,
- 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x12, 0x26, 0x0a, 0x06, 0x6f, 0x75, 0x74, 0x70, 0x75,
- 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e,
- 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x52, 0x06, 0x6f, 0x75, 0x74, 0x70, 0x75, 0x74, 0x22,
- 0x32, 0x0a, 0x11, 0x47, 0x65, 0x74, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71,
- 0x75, 0x65, 0x73, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x5f,
- 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f,
- 0x6e, 0x49, 0x64, 0x22, 0xf7, 0x01, 0x0a, 0x0b, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x49,
- 0x6e, 0x66, 0x6f, 0x12, 0x22, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x01, 0x20, 0x01,
- 0x28, 0x0e, 0x32, 0x0c, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x65,
- 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x12, 0x23, 0x0a, 0x0d, 0x61, 0x63, 0x74, 0x69, 0x76,
- 0x65, 0x5f, 0x61, 0x67, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0c,
- 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x73, 0x12, 0x29, 0x0a, 0x10,
- 0x63, 0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74,
- 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0f, 0x63, 0x68, 0x65, 0x63, 0x6b, 0x70, 0x6f, 0x69,
- 0x6e, 0x74, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x39, 0x0a, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74,
- 0x65, 0x64, 0x5f, 0x61, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f,
- 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69,
- 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x09, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64,
- 0x41, 0x74, 0x12, 0x39, 0x0a, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x61, 0x74,
- 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e,
- 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61,
- 0x6d, 0x70, 0x52, 0x09, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x22, 0x42, 0x0a,
- 0x12, 0x47, 0x65, 0x74, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f,
- 0x6e, 0x73, 0x65, 0x12, 0x2c, 0x0a, 0x07, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x01,
- 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x53, 0x65, 0x73,
- 0x73, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x07, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f,
- 0x6e, 0x22, 0x85, 0x02, 0x0a, 0x14, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x41, 0x67,
- 0x65, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x19, 0x0a, 0x08, 0x61, 0x67,
- 0x65, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x67,
- 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20,
- 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x64, 0x65, 0x73,
- 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b,
- 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x18, 0x0a, 0x07, 0x61,
- 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x64,
- 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x45, 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74,
- 0x61, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x29, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e,
- 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x71,
- 0x75, 0x65, 0x73, 0x74, 0x2e, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x45, 0x6e, 0x74,
- 0x72, 0x79, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x1a, 0x3b, 0x0a, 0x0d,
- 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a,
- 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12,
- 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05,
- 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x17, 0x0a, 0x15, 0x52, 0x65, 0x67,
- 0x69, 0x73, 0x74, 0x65, 0x72, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e,
- 0x73, 0x65, 0x22, 0x33, 0x0a, 0x16, 0x55, 0x6e, 0x72, 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72,
- 0x41, 0x67, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x19, 0x0a, 0x08,
- 0x61, 0x67, 0x65, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07,
- 0x61, 0x67, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x22, 0x19, 0x0a, 0x17, 0x55, 0x6e, 0x72, 0x65, 0x67,
- 0x69, 0x73, 0x74, 0x65, 0x72, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e,
- 0x73, 0x65, 0x2a, 0x58, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x15, 0x0a, 0x11, 0x53,
- 0x54, 0x41, 0x54, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44,
- 0x10, 0x00, 0x12, 0x11, 0x0a, 0x0d, 0x53, 0x54, 0x41, 0x54, 0x45, 0x5f, 0x52, 0x55, 0x4e, 0x4e,
- 0x49, 0x4e, 0x47, 0x10, 0x01, 0x12, 0x10, 0x0a, 0x0c, 0x53, 0x54, 0x41, 0x54, 0x45, 0x5f, 0x46,
- 0x41, 0x49, 0x4c, 0x45, 0x44, 0x10, 0x02, 0x12, 0x13, 0x0a, 0x0f, 0x53, 0x54, 0x41, 0x54, 0x45,
- 0x5f, 0x43, 0x4f, 0x4d, 0x50, 0x4c, 0x45, 0x54, 0x45, 0x44, 0x10, 0x03, 0x32, 0x83, 0x01, 0x0a,
- 0x0c, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x2d, 0x0a,
- 0x07, 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x12, 0x0e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
- 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x1a, 0x0e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
- 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x28, 0x01, 0x30, 0x01, 0x12, 0x44, 0x0a, 0x0b,
- 0x48, 0x65, 0x61, 0x6c, 0x74, 0x68, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x12, 0x19, 0x2e, 0x70, 0x72,
- 0x6f, 0x74, 0x6f, 0x2e, 0x48, 0x65, 0x61, 0x6c, 0x74, 0x68, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x52,
- 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1a, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x48,
- 0x65, 0x61, 0x6c, 0x74, 0x68, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e,
- 0x73, 0x65, 0x32, 0xbe, 0x02, 0x0a, 0x0a, 0x47, 0x41, 0x52, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63,
- 0x65, 0x12, 0x4f, 0x0a, 0x0e, 0x54, 0x72, 0x69, 0x67, 0x67, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73,
- 0x69, 0x6f, 0x6e, 0x12, 0x1c, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x54, 0x72, 0x69, 0x67,
- 0x67, 0x65, 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73,
- 0x74, 0x1a, 0x1d, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x54, 0x72, 0x69, 0x67, 0x67, 0x65,
- 0x72, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65,
- 0x30, 0x01, 0x12, 0x41, 0x0a, 0x0a, 0x47, 0x65, 0x74, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e,
- 0x12, 0x18, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x47, 0x65, 0x74, 0x53, 0x65, 0x73, 0x73,
- 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x70, 0x72, 0x6f,
- 0x74, 0x6f, 0x2e, 0x47, 0x65, 0x74, 0x53, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73,
- 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x4a, 0x0a, 0x0d, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x65,
- 0x72, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x12, 0x1b, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x52,
- 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75,
- 0x65, 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x52, 0x65, 0x67, 0x69,
- 0x73, 0x74, 0x65, 0x72, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73,
- 0x65, 0x12, 0x50, 0x0a, 0x0f, 0x55, 0x6e, 0x72, 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x41,
- 0x67, 0x65, 0x6e, 0x74, 0x12, 0x1d, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x55, 0x6e, 0x72,
- 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75,
- 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x55, 0x6e, 0x72, 0x65,
- 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f,
- 0x6e, 0x73, 0x65, 0x42, 0x1d, 0x5a, 0x1b, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f,
- 0x6d, 0x2f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x67, 0x61, 0x72, 0x2f, 0x70, 0x72, 0x6f,
- 0x74, 0x6f, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
-}
+const file_proto_gar_proto_rawDesc = "" +
+ "\n" +
+ "\x0fproto/gar.proto\x12\x05proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\x86\x01\n" +
+ "\aContent\x12#\n" +
+ "\rcheckpoint_id\x18\x01 \x01(\tR\fcheckpointId\x12\x12\n" +
+ "\x04role\x18\x02 \x01(\tR\x04role\x12\x12\n" +
+ "\x04type\x18\x03 \x01(\tR\x04type\x12\x1a\n" +
+ "\bmimetype\x18\x04 \x01(\tR\bmimetype\x12\x12\n" +
+ "\x04data\x18\x05 \x01(\tR\x04data\"\x14\n" +
+ "\x12HealthCheckRequest\"I\n" +
+ "\x13HealthCheckResponse\x12\x18\n" +
+ "\ahealthy\x18\x01 \x01(\bR\ahealthy\x12\x18\n" +
+ "\amessage\x18\x02 \x01(\tR\amessage\"\x83\x01\n" +
+ "\x15TriggerSessionRequest\x12\x1d\n" +
+ "\n" +
+ "session_id\x18\x01 \x01(\tR\tsessionId\x12#\n" +
+ "\rcheckpoint_id\x18\x02 \x01(\tR\fcheckpointId\x12&\n" +
+ "\x06inputs\x18\x03 \x03(\v2\x0e.proto.ContentR\x06inputs\"\x83\x01\n" +
+ "\x16TriggerSessionResponse\x12\x1d\n" +
+ "\n" +
+ "session_id\x18\x01 \x01(\tR\tsessionId\x12\"\n" +
+ "\x05state\x18\x02 \x01(\x0e2\f.proto.StateR\x05state\x12&\n" +
+ "\x06output\x18\x03 \x01(\v2\x0e.proto.ContentR\x06output\"2\n" +
+ "\x11GetSessionRequest\x12\x1d\n" +
+ "\n" +
+ "session_id\x18\x01 \x01(\tR\tsessionId\"\xf3\x01\n" +
+ "\vSessionInfo\x12\"\n" +
+ "\x05state\x18\x01 \x01(\x0e2\f.proto.StateR\x05state\x12#\n" +
+ "\ractive_agents\x18\x02 \x03(\tR\factiveAgents\x12%\n" +
+ "\x0echeckpoint_ids\x18\x03 \x03(\tR\rcheckpointIds\x129\n" +
+ "\n" +
+ "created_at\x18\x04 \x01(\v2\x1a.google.protobuf.TimestampR\tcreatedAt\x129\n" +
+ "\n" +
+ "updated_at\x18\x05 \x01(\v2\x1a.google.protobuf.TimestampR\tupdatedAt\"B\n" +
+ "\x12GetSessionResponse\x12,\n" +
+ "\asession\x18\x01 \x01(\v2\x12.proto.SessionInfoR\asession\"\x85\x02\n" +
+ "\x14RegisterAgentRequest\x12\x19\n" +
+ "\bagent_id\x18\x01 \x01(\tR\aagentId\x12\x12\n" +
+ "\x04name\x18\x02 \x01(\tR\x04name\x12 \n" +
+ "\vdescription\x18\x03 \x01(\tR\vdescription\x12\x18\n" +
+ "\aaddress\x18\x04 \x01(\tR\aaddress\x12E\n" +
+ "\bmetadata\x18\x05 \x03(\v2).proto.RegisterAgentRequest.MetadataEntryR\bmetadata\x1a;\n" +
+ "\rMetadataEntry\x12\x10\n" +
+ "\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" +
+ "\x05value\x18\x02 \x01(\tR\x05value:\x028\x01\"\x17\n" +
+ "\x15RegisterAgentResponse\"3\n" +
+ "\x16UnregisterAgentRequest\x12\x19\n" +
+ "\bagent_id\x18\x01 \x01(\tR\aagentId\"\x19\n" +
+ "\x17UnregisterAgentResponse*X\n" +
+ "\x05State\x12\x15\n" +
+ "\x11STATE_UNSPECIFIED\x10\x00\x12\x11\n" +
+ "\rSTATE_RUNNING\x10\x01\x12\x10\n" +
+ "\fSTATE_FAILED\x10\x02\x12\x13\n" +
+ "\x0fSTATE_COMPLETED\x10\x032\x83\x01\n" +
+ "\fAgentService\x12-\n" +
+ "\aProcess\x12\x0e.proto.Content\x1a\x0e.proto.Content(\x010\x01\x12D\n" +
+ "\vHealthCheck\x12\x19.proto.HealthCheckRequest\x1a\x1a.proto.HealthCheckResponse2\xbe\x02\n" +
+ "\n" +
+ "GARService\x12O\n" +
+ "\x0eTriggerSession\x12\x1c.proto.TriggerSessionRequest\x1a\x1d.proto.TriggerSessionResponse0\x01\x12A\n" +
+ "\n" +
+ "GetSession\x12\x18.proto.GetSessionRequest\x1a\x19.proto.GetSessionResponse\x12J\n" +
+ "\rRegisterAgent\x12\x1b.proto.RegisterAgentRequest\x1a\x1c.proto.RegisterAgentResponse\x12P\n" +
+ "\x0fUnregisterAgent\x12\x1d.proto.UnregisterAgentRequest\x1a\x1e.proto.UnregisterAgentResponseB\x1dZ\x1bgithub.com/google/gar/protob\x06proto3"
var (
file_proto_gar_proto_rawDescOnce sync.Once
- file_proto_gar_proto_rawDescData = file_proto_gar_proto_rawDesc
+ file_proto_gar_proto_rawDescData []byte
)
func file_proto_gar_proto_rawDescGZIP() []byte {
file_proto_gar_proto_rawDescOnce.Do(func() {
- file_proto_gar_proto_rawDescData = protoimpl.X.CompressGZIP(file_proto_gar_proto_rawDescData)
+ file_proto_gar_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_proto_gar_proto_rawDesc), len(file_proto_gar_proto_rawDesc)))
})
return file_proto_gar_proto_rawDescData
}
@@ -940,7 +876,7 @@ func file_proto_gar_proto_init() {
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
- RawDescriptor: file_proto_gar_proto_rawDesc,
+ RawDescriptor: unsafe.Slice(unsafe.StringData(file_proto_gar_proto_rawDesc), len(file_proto_gar_proto_rawDesc)),
NumEnums: 1,
NumMessages: 13,
NumExtensions: 0,
@@ -952,7 +888,6 @@ func file_proto_gar_proto_init() {
MessageInfos: file_proto_gar_proto_msgTypes,
}.Build()
File_proto_gar_proto = out.File
- file_proto_gar_proto_rawDesc = nil
file_proto_gar_proto_goTypes = nil
file_proto_gar_proto_depIdxs = nil
}
diff --git a/proto/gar.proto b/proto/gar.proto
index 0823f82..7583510 100644
--- a/proto/gar.proto
+++ b/proto/gar.proto
@@ -22,11 +22,11 @@ option go_package = "github.com/google/gar/proto";
// Content represents a message with role, type, mimetype, and data fields
message Content {
- string role = 1; // The role of the content (e.g., "user", "assistant", "system")
- string type = 2; // The type of content (e.g., "text", "image")
- string mimetype = 3; // MIME type of the data (e.g., "text/plain", "image/png")
- string data = 4; // The actual content data
- string checkpoint_id = 5; // Optional: Checkpoint ID for this content
+ string checkpoint_id = 1; // Optional: Checkpoint ID for this content
+ string role = 2; // The role of the content (e.g., "user", "assistant", "system")
+ string type = 3; // The type of content (e.g., "text", "image")
+ string mimetype = 4; // MIME type of the data (e.g., "text/plain", "image/png")
+ string data = 5; // The actual content data
// TODO: Replace Content with Interactions Content.
}
@@ -83,7 +83,7 @@ message GetSessionRequest {
message SessionInfo {
State state = 1;
repeated string active_agents = 2;
- int32 checkpoint_count = 3;
+ repeated string checkpoint_ids = 3;
google.protobuf.Timestamp created_at = 4; // Session creation time
google.protobuf.Timestamp updated_at = 5; // Last update time
}
diff --git a/proto/gar_grpc.pb.go b/proto/gar_grpc.pb.go
index e5e4fba..84695ec 100644
--- a/proto/gar_grpc.pb.go
+++ b/proto/gar_grpc.pb.go
@@ -14,15 +14,14 @@
// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
// versions:
-// - protoc-gen-go-grpc v1.5.1
-// - protoc v5.28.2
+// - protoc-gen-go-grpc v1.6.0
+// - protoc v3.21.9
// source: proto/gar.proto
package proto
import (
context "context"
-
grpc "google.golang.org/grpc"
codes "google.golang.org/grpc/codes"
status "google.golang.org/grpc/status"
@@ -102,10 +101,10 @@ type AgentServiceServer interface {
type UnimplementedAgentServiceServer struct{}
func (UnimplementedAgentServiceServer) Process(grpc.BidiStreamingServer[Content, Content]) error {
- return status.Errorf(codes.Unimplemented, "method Process not implemented")
+ return status.Error(codes.Unimplemented, "method Process not implemented")
}
func (UnimplementedAgentServiceServer) HealthCheck(context.Context, *HealthCheckRequest) (*HealthCheckResponse, error) {
- return nil, status.Errorf(codes.Unimplemented, "method HealthCheck not implemented")
+ return nil, status.Error(codes.Unimplemented, "method HealthCheck not implemented")
}
func (UnimplementedAgentServiceServer) mustEmbedUnimplementedAgentServiceServer() {}
func (UnimplementedAgentServiceServer) testEmbeddedByValue() {}
@@ -118,7 +117,7 @@ type UnsafeAgentServiceServer interface {
}
func RegisterAgentServiceServer(s grpc.ServiceRegistrar, srv AgentServiceServer) {
- // If the following call pancis, it indicates UnimplementedAgentServiceServer was
+ // If the following call panics, it indicates UnimplementedAgentServiceServer was
// embedded by pointer and is nil. This will cause panics if an
// unimplemented method is ever invoked, so we test this at initialization
// time to prevent it from happening at runtime later due to I/O.
@@ -283,16 +282,16 @@ type GARServiceServer interface {
type UnimplementedGARServiceServer struct{}
func (UnimplementedGARServiceServer) TriggerSession(*TriggerSessionRequest, grpc.ServerStreamingServer[TriggerSessionResponse]) error {
- return status.Errorf(codes.Unimplemented, "method TriggerSession not implemented")
+ return status.Error(codes.Unimplemented, "method TriggerSession not implemented")
}
func (UnimplementedGARServiceServer) GetSession(context.Context, *GetSessionRequest) (*GetSessionResponse, error) {
- return nil, status.Errorf(codes.Unimplemented, "method GetSession not implemented")
+ return nil, status.Error(codes.Unimplemented, "method GetSession not implemented")
}
func (UnimplementedGARServiceServer) RegisterAgent(context.Context, *RegisterAgentRequest) (*RegisterAgentResponse, error) {
- return nil, status.Errorf(codes.Unimplemented, "method RegisterAgent not implemented")
+ return nil, status.Error(codes.Unimplemented, "method RegisterAgent not implemented")
}
func (UnimplementedGARServiceServer) UnregisterAgent(context.Context, *UnregisterAgentRequest) (*UnregisterAgentResponse, error) {
- return nil, status.Errorf(codes.Unimplemented, "method UnregisterAgent not implemented")
+ return nil, status.Error(codes.Unimplemented, "method UnregisterAgent not implemented")
}
func (UnimplementedGARServiceServer) mustEmbedUnimplementedGARServiceServer() {}
func (UnimplementedGARServiceServer) testEmbeddedByValue() {}
@@ -305,7 +304,7 @@ type UnsafeGARServiceServer interface {
}
func RegisterGARServiceServer(s grpc.ServiceRegistrar, srv GARServiceServer) {
- // If the following call pancis, it indicates UnimplementedGARServiceServer was
+ // If the following call panics, it indicates UnimplementedGARServiceServer was
// embedded by pointer and is nil. This will cause panics if an
// unimplemented method is ever invoked, so we test this at initialization
// time to prevent it from happening at runtime later due to I/O.