bob

package
v0.7.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 12, 2026 License: Apache-2.0 Imports: 5 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package bob is the agent for IBM Bob: the Bob IDE and Bob Shell. Its init() registers it in the agent package's default registry, so a host needs only a blank import:

import _ "github.com/rossoctl/context-guru/agent/bob"

This is a library package. It never imports a host. imports_test.go enforces that.

Index

Constants

View Source
const ModelPath = "/inference/v1/chat/completions"

ModelPath is Bob's model route. It is the only route Bob owns.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bob

type Bob struct{ agent.Base }

Bob overrides only where it differs from the neutral agent.

func (Bob) ModelTarget

func (Bob) ModelTarget() agent.ModelTarget

ModelTarget sends the host's own calls to Bob's model path: Bob serves chat on no other path. Bob takes the key as `Authorization: Apikey <key>`, the way the Bob client sends it.

func (Bob) Name

func (Bob) Name() string

Name is the label the dashboard already gives Bob.

func (Bob) Paths

func (Bob) Paths() []string

func (Bob) ReadUsage

func (Bob) ReadUsage(contentType string, reply []byte, base agent.Usage) agent.Usage

ReadUsage reads the cache writes from a reply on Bob's model route: the top-level `usage` of a JSON body, or the last `usage` chunk of an OpenAI chat event stream.

func (Bob) SessionID

func (Bob) SessionID(h http.Header) string

SessionID is the Bob IDE's task id. The IDE sends it only in the X-Task-Id header, not in the body. Bob Shell sends metadata.taskId in the body, which the host reads before this.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL