ent

package
v0.5.1 Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2026 License: MIT Imports: 25 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Operation types.
	OpCreate    = ent.OpCreate
	OpDelete    = ent.OpDelete
	OpDeleteOne = ent.OpDeleteOne
	OpUpdate    = ent.OpUpdate
	OpUpdateOne = ent.OpUpdateOne

	// Node types.
	TypeAgentEvent     = "AgentEvent"
	TypeAgentHandoff   = "AgentHandoff"
	TypeAgentTask      = "AgentTask"
	TypeToolInvocation = "ToolInvocation"
	TypeWorkflow       = "Workflow"
)

Variables

View Source
var ErrTxStarted = errors.New("ent: cannot start a transaction within a transaction")

ErrTxStarted is returned when trying to start a new transaction from a transactional client.

Functions

func Asc

func Asc(fields ...string) func(*sql.Selector)

Asc applies the given fields in ASC order.

func Desc

func Desc(fields ...string) func(*sql.Selector)

Desc applies the given fields in DESC order.

func IsConstraintError

func IsConstraintError(err error) bool

IsConstraintError returns a boolean indicating whether the error is a constraint failure.

func IsNotFound

func IsNotFound(err error) bool

IsNotFound returns a boolean indicating whether the error is a not found error.

func IsNotLoaded

func IsNotLoaded(err error) bool

IsNotLoaded returns a boolean indicating whether the error is a not loaded error.

func IsNotSingular

func IsNotSingular(err error) bool

IsNotSingular returns a boolean indicating whether the error is a not singular error.

func IsValidationError

func IsValidationError(err error) bool

IsValidationError returns a boolean indicating whether the error is a validation error.

func MaskNotFound

func MaskNotFound(err error) error

MaskNotFound masks not found error.

func NewContext

func NewContext(parent context.Context, c *Client) context.Context

NewContext returns a new context with the given Client attached.

func NewTxContext

func NewTxContext(parent context.Context, tx *Tx) context.Context

NewTxContext returns a new context with the given Tx attached.

Types

type AgentEvent

type AgentEvent struct {

	// ID of the ent.
	// Unique event identifier (UUID)
	ID string `json:"id,omitempty"`
	// Event type (e.g., 'agent.task.started', 'domain.statistic.extracted')
	EventType string `json:"event_type,omitempty"`
	// Event category: agent, workflow, tool, domain, system
	EventCategory string `json:"event_category,omitempty"`
	// Associated workflow ID
	WorkflowID string `json:"workflow_id,omitempty"`
	// Associated task ID
	TaskID string `json:"task_id,omitempty"`
	// Associated agent ID
	AgentID string `json:"agent_id,omitempty"`
	// OpenTelemetry trace ID
	TraceID string `json:"trace_id,omitempty"`
	// OpenTelemetry span ID
	SpanID string `json:"span_id,omitempty"`
	// Event severity: debug, info, warn, error
	Severity string `json:"severity,omitempty"`
	// Event payload data
	Data map[string]interface{} `json:"data,omitempty"`
	// Additional metadata
	Metadata map[string]interface{} `json:"metadata,omitempty"`
	// Event tags for filtering
	Tags []string `json:"tags,omitempty"`
	// Source of the event (service name, component)
	Source string `json:"source,omitempty"`
	// Event schema version
	Version string `json:"version,omitempty"`
	// When the event occurred
	Timestamp time.Time `json:"timestamp,omitempty"`
	// CreatedAt holds the value of the "created_at" field.
	CreatedAt time.Time `json:"created_at,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the AgentEventQuery when eager-loading is set.
	Edges AgentEventEdges `json:"edges"`
	// contains filtered or unexported fields
}

AgentEvent is the model entity for the AgentEvent schema.

func (*AgentEvent) QueryTask

func (ae *AgentEvent) QueryTask() *AgentTaskQuery

QueryTask queries the "task" edge of the AgentEvent entity.

func (*AgentEvent) QueryWorkflow

func (ae *AgentEvent) QueryWorkflow() *WorkflowQuery

QueryWorkflow queries the "workflow" edge of the AgentEvent entity.

func (*AgentEvent) String

func (ae *AgentEvent) String() string

String implements the fmt.Stringer.

func (*AgentEvent) Unwrap

func (ae *AgentEvent) Unwrap() *AgentEvent

Unwrap unwraps the AgentEvent entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*AgentEvent) Update

func (ae *AgentEvent) Update() *AgentEventUpdateOne

Update returns a builder for updating this AgentEvent. Note that you need to call AgentEvent.Unwrap() before calling this method if this AgentEvent was returned from a transaction, and the transaction was committed or rolled back.

func (*AgentEvent) Value

func (ae *AgentEvent) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the AgentEvent. This includes values selected through modifiers, order, etc.

type AgentEventClient

type AgentEventClient struct {
	// contains filtered or unexported fields
}

AgentEventClient is a client for the AgentEvent schema.

func NewAgentEventClient

func NewAgentEventClient(c config) *AgentEventClient

NewAgentEventClient returns a client for the AgentEvent from the given config.

func (*AgentEventClient) Create

func (c *AgentEventClient) Create() *AgentEventCreate

Create returns a builder for creating a AgentEvent entity.

func (*AgentEventClient) CreateBulk

func (c *AgentEventClient) CreateBulk(builders ...*AgentEventCreate) *AgentEventCreateBulk

CreateBulk returns a builder for creating a bulk of AgentEvent entities.

func (*AgentEventClient) Delete

func (c *AgentEventClient) Delete() *AgentEventDelete

Delete returns a delete builder for AgentEvent.

func (*AgentEventClient) DeleteOne

func (c *AgentEventClient) DeleteOne(ae *AgentEvent) *AgentEventDeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*AgentEventClient) DeleteOneID

func (c *AgentEventClient) DeleteOneID(id string) *AgentEventDeleteOne

DeleteOneID returns a builder for deleting the given entity by its id.

func (*AgentEventClient) Get

func (c *AgentEventClient) Get(ctx context.Context, id string) (*AgentEvent, error)

Get returns a AgentEvent entity by its id.

func (*AgentEventClient) GetX

func (c *AgentEventClient) GetX(ctx context.Context, id string) *AgentEvent

GetX is like Get, but panics if an error occurs.

func (*AgentEventClient) Hooks

func (c *AgentEventClient) Hooks() []Hook

Hooks returns the client hooks.

func (*AgentEventClient) Intercept

func (c *AgentEventClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `agentevent.Intercept(f(g(h())))`.

func (*AgentEventClient) Interceptors

func (c *AgentEventClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*AgentEventClient) MapCreateBulk

func (c *AgentEventClient) MapCreateBulk(slice any, setFunc func(*AgentEventCreate, int)) *AgentEventCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*AgentEventClient) Query

func (c *AgentEventClient) Query() *AgentEventQuery

Query returns a query builder for AgentEvent.

func (*AgentEventClient) QueryTask

func (c *AgentEventClient) QueryTask(ae *AgentEvent) *AgentTaskQuery

QueryTask queries the task edge of a AgentEvent.

func (*AgentEventClient) QueryWorkflow

func (c *AgentEventClient) QueryWorkflow(ae *AgentEvent) *WorkflowQuery

QueryWorkflow queries the workflow edge of a AgentEvent.

func (*AgentEventClient) Update

func (c *AgentEventClient) Update() *AgentEventUpdate

Update returns an update builder for AgentEvent.

func (*AgentEventClient) UpdateOne

func (c *AgentEventClient) UpdateOne(ae *AgentEvent) *AgentEventUpdateOne

UpdateOne returns an update builder for the given entity.

func (*AgentEventClient) UpdateOneID

func (c *AgentEventClient) UpdateOneID(id string) *AgentEventUpdateOne

UpdateOneID returns an update builder for the given id.

func (*AgentEventClient) Use

func (c *AgentEventClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `agentevent.Hooks(f(g(h())))`.

type AgentEventCreate

type AgentEventCreate struct {
	// contains filtered or unexported fields
}

AgentEventCreate is the builder for creating a AgentEvent entity.

func (*AgentEventCreate) Exec

func (aec *AgentEventCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*AgentEventCreate) ExecX

func (aec *AgentEventCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*AgentEventCreate) Mutation

func (aec *AgentEventCreate) Mutation() *AgentEventMutation

Mutation returns the AgentEventMutation object of the builder.

func (*AgentEventCreate) Save

func (aec *AgentEventCreate) Save(ctx context.Context) (*AgentEvent, error)

Save creates the AgentEvent in the database.

func (*AgentEventCreate) SaveX

func (aec *AgentEventCreate) SaveX(ctx context.Context) *AgentEvent

SaveX calls Save and panics if Save returns an error.

func (*AgentEventCreate) SetAgentID

func (aec *AgentEventCreate) SetAgentID(s string) *AgentEventCreate

SetAgentID sets the "agent_id" field.

func (*AgentEventCreate) SetCreatedAt

func (aec *AgentEventCreate) SetCreatedAt(t time.Time) *AgentEventCreate

SetCreatedAt sets the "created_at" field.

func (*AgentEventCreate) SetData

func (aec *AgentEventCreate) SetData(m map[string]interface{}) *AgentEventCreate

SetData sets the "data" field.

func (*AgentEventCreate) SetEventCategory

func (aec *AgentEventCreate) SetEventCategory(s string) *AgentEventCreate

SetEventCategory sets the "event_category" field.

func (*AgentEventCreate) SetEventType

func (aec *AgentEventCreate) SetEventType(s string) *AgentEventCreate

SetEventType sets the "event_type" field.

func (*AgentEventCreate) SetID

func (aec *AgentEventCreate) SetID(s string) *AgentEventCreate

SetID sets the "id" field.

func (*AgentEventCreate) SetMetadata

func (aec *AgentEventCreate) SetMetadata(m map[string]interface{}) *AgentEventCreate

SetMetadata sets the "metadata" field.

func (*AgentEventCreate) SetNillableAgentID

func (aec *AgentEventCreate) SetNillableAgentID(s *string) *AgentEventCreate

SetNillableAgentID sets the "agent_id" field if the given value is not nil.

func (*AgentEventCreate) SetNillableCreatedAt

func (aec *AgentEventCreate) SetNillableCreatedAt(t *time.Time) *AgentEventCreate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*AgentEventCreate) SetNillableEventCategory

func (aec *AgentEventCreate) SetNillableEventCategory(s *string) *AgentEventCreate

SetNillableEventCategory sets the "event_category" field if the given value is not nil.

func (*AgentEventCreate) SetNillableSeverity

func (aec *AgentEventCreate) SetNillableSeverity(s *string) *AgentEventCreate

SetNillableSeverity sets the "severity" field if the given value is not nil.

func (*AgentEventCreate) SetNillableSource

func (aec *AgentEventCreate) SetNillableSource(s *string) *AgentEventCreate

SetNillableSource sets the "source" field if the given value is not nil.

func (*AgentEventCreate) SetNillableSpanID

func (aec *AgentEventCreate) SetNillableSpanID(s *string) *AgentEventCreate

SetNillableSpanID sets the "span_id" field if the given value is not nil.

func (*AgentEventCreate) SetNillableTaskID

func (aec *AgentEventCreate) SetNillableTaskID(s *string) *AgentEventCreate

SetNillableTaskID sets the "task_id" field if the given value is not nil.

func (*AgentEventCreate) SetNillableTimestamp

func (aec *AgentEventCreate) SetNillableTimestamp(t *time.Time) *AgentEventCreate

SetNillableTimestamp sets the "timestamp" field if the given value is not nil.

func (*AgentEventCreate) SetNillableTraceID

func (aec *AgentEventCreate) SetNillableTraceID(s *string) *AgentEventCreate

SetNillableTraceID sets the "trace_id" field if the given value is not nil.

func (*AgentEventCreate) SetNillableVersion

func (aec *AgentEventCreate) SetNillableVersion(s *string) *AgentEventCreate

SetNillableVersion sets the "version" field if the given value is not nil.

func (*AgentEventCreate) SetNillableWorkflowID

func (aec *AgentEventCreate) SetNillableWorkflowID(s *string) *AgentEventCreate

SetNillableWorkflowID sets the "workflow_id" field if the given value is not nil.

func (*AgentEventCreate) SetSeverity

func (aec *AgentEventCreate) SetSeverity(s string) *AgentEventCreate

SetSeverity sets the "severity" field.

func (*AgentEventCreate) SetSource

func (aec *AgentEventCreate) SetSource(s string) *AgentEventCreate

SetSource sets the "source" field.

func (*AgentEventCreate) SetSpanID

func (aec *AgentEventCreate) SetSpanID(s string) *AgentEventCreate

SetSpanID sets the "span_id" field.

func (*AgentEventCreate) SetTags

func (aec *AgentEventCreate) SetTags(s []string) *AgentEventCreate

SetTags sets the "tags" field.

func (*AgentEventCreate) SetTask

func (aec *AgentEventCreate) SetTask(a *AgentTask) *AgentEventCreate

SetTask sets the "task" edge to the AgentTask entity.

func (*AgentEventCreate) SetTaskID

func (aec *AgentEventCreate) SetTaskID(s string) *AgentEventCreate

SetTaskID sets the "task_id" field.

func (*AgentEventCreate) SetTimestamp

func (aec *AgentEventCreate) SetTimestamp(t time.Time) *AgentEventCreate

SetTimestamp sets the "timestamp" field.

func (*AgentEventCreate) SetTraceID

func (aec *AgentEventCreate) SetTraceID(s string) *AgentEventCreate

SetTraceID sets the "trace_id" field.

func (*AgentEventCreate) SetVersion

func (aec *AgentEventCreate) SetVersion(s string) *AgentEventCreate

SetVersion sets the "version" field.

func (*AgentEventCreate) SetWorkflow

func (aec *AgentEventCreate) SetWorkflow(w *Workflow) *AgentEventCreate

SetWorkflow sets the "workflow" edge to the Workflow entity.

func (*AgentEventCreate) SetWorkflowID

func (aec *AgentEventCreate) SetWorkflowID(s string) *AgentEventCreate

SetWorkflowID sets the "workflow_id" field.

type AgentEventCreateBulk

type AgentEventCreateBulk struct {
	// contains filtered or unexported fields
}

AgentEventCreateBulk is the builder for creating many AgentEvent entities in bulk.

func (*AgentEventCreateBulk) Exec

func (aecb *AgentEventCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*AgentEventCreateBulk) ExecX

func (aecb *AgentEventCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*AgentEventCreateBulk) Save

func (aecb *AgentEventCreateBulk) Save(ctx context.Context) ([]*AgentEvent, error)

Save creates the AgentEvent entities in the database.

func (*AgentEventCreateBulk) SaveX

func (aecb *AgentEventCreateBulk) SaveX(ctx context.Context) []*AgentEvent

SaveX is like Save, but panics if an error occurs.

type AgentEventDelete

type AgentEventDelete struct {
	// contains filtered or unexported fields
}

AgentEventDelete is the builder for deleting a AgentEvent entity.

func (*AgentEventDelete) Exec

func (aed *AgentEventDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*AgentEventDelete) ExecX

func (aed *AgentEventDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*AgentEventDelete) Where

Where appends a list predicates to the AgentEventDelete builder.

type AgentEventDeleteOne

type AgentEventDeleteOne struct {
	// contains filtered or unexported fields
}

AgentEventDeleteOne is the builder for deleting a single AgentEvent entity.

func (*AgentEventDeleteOne) Exec

func (aedo *AgentEventDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*AgentEventDeleteOne) ExecX

func (aedo *AgentEventDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*AgentEventDeleteOne) Where

Where appends a list predicates to the AgentEventDelete builder.

type AgentEventEdges

type AgentEventEdges struct {
	// Workflow holds the value of the workflow edge.
	Workflow *Workflow `json:"workflow,omitempty"`
	// Task holds the value of the task edge.
	Task *AgentTask `json:"task,omitempty"`
	// contains filtered or unexported fields
}

AgentEventEdges holds the relations/edges for other nodes in the graph.

func (AgentEventEdges) TaskOrErr

func (e AgentEventEdges) TaskOrErr() (*AgentTask, error)

TaskOrErr returns the Task value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

func (AgentEventEdges) WorkflowOrErr

func (e AgentEventEdges) WorkflowOrErr() (*Workflow, error)

WorkflowOrErr returns the Workflow value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

type AgentEventGroupBy

type AgentEventGroupBy struct {
	// contains filtered or unexported fields
}

AgentEventGroupBy is the group-by builder for AgentEvent entities.

func (*AgentEventGroupBy) Aggregate

func (aegb *AgentEventGroupBy) Aggregate(fns ...AggregateFunc) *AgentEventGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*AgentEventGroupBy) Bool

func (s *AgentEventGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*AgentEventGroupBy) BoolX

func (s *AgentEventGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*AgentEventGroupBy) Bools

func (s *AgentEventGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*AgentEventGroupBy) BoolsX

func (s *AgentEventGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*AgentEventGroupBy) Float64

func (s *AgentEventGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*AgentEventGroupBy) Float64X

func (s *AgentEventGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*AgentEventGroupBy) Float64s

func (s *AgentEventGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*AgentEventGroupBy) Float64sX

func (s *AgentEventGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*AgentEventGroupBy) Int

func (s *AgentEventGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*AgentEventGroupBy) IntX

func (s *AgentEventGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*AgentEventGroupBy) Ints

func (s *AgentEventGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*AgentEventGroupBy) IntsX

func (s *AgentEventGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*AgentEventGroupBy) Scan

func (aegb *AgentEventGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*AgentEventGroupBy) ScanX

func (s *AgentEventGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*AgentEventGroupBy) String

func (s *AgentEventGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*AgentEventGroupBy) StringX

func (s *AgentEventGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*AgentEventGroupBy) Strings

func (s *AgentEventGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*AgentEventGroupBy) StringsX

func (s *AgentEventGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type AgentEventMutation

type AgentEventMutation struct {
	// contains filtered or unexported fields
}

AgentEventMutation represents an operation that mutates the AgentEvent nodes in the graph.

func (*AgentEventMutation) AddField

func (m *AgentEventMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*AgentEventMutation) AddedEdges

func (m *AgentEventMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*AgentEventMutation) AddedField

func (m *AgentEventMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*AgentEventMutation) AddedFields

func (m *AgentEventMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*AgentEventMutation) AddedIDs

func (m *AgentEventMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*AgentEventMutation) AgentID

func (m *AgentEventMutation) AgentID() (r string, exists bool)

AgentID returns the value of the "agent_id" field in the mutation.

func (*AgentEventMutation) AgentIDCleared

func (m *AgentEventMutation) AgentIDCleared() bool

AgentIDCleared returns if the "agent_id" field was cleared in this mutation.

func (*AgentEventMutation) AppendTags

func (m *AgentEventMutation) AppendTags(s []string)

AppendTags adds s to the "tags" field.

func (*AgentEventMutation) AppendedTags

func (m *AgentEventMutation) AppendedTags() ([]string, bool)

AppendedTags returns the list of values that were appended to the "tags" field in this mutation.

func (*AgentEventMutation) ClearAgentID

func (m *AgentEventMutation) ClearAgentID()

ClearAgentID clears the value of the "agent_id" field.

func (*AgentEventMutation) ClearData

func (m *AgentEventMutation) ClearData()

ClearData clears the value of the "data" field.

func (*AgentEventMutation) ClearEdge

func (m *AgentEventMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*AgentEventMutation) ClearField

func (m *AgentEventMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*AgentEventMutation) ClearMetadata

func (m *AgentEventMutation) ClearMetadata()

ClearMetadata clears the value of the "metadata" field.

func (*AgentEventMutation) ClearSource

func (m *AgentEventMutation) ClearSource()

ClearSource clears the value of the "source" field.

func (*AgentEventMutation) ClearSpanID

func (m *AgentEventMutation) ClearSpanID()

ClearSpanID clears the value of the "span_id" field.

func (*AgentEventMutation) ClearTags

func (m *AgentEventMutation) ClearTags()

ClearTags clears the value of the "tags" field.

func (*AgentEventMutation) ClearTask

func (m *AgentEventMutation) ClearTask()

ClearTask clears the "task" edge to the AgentTask entity.

func (*AgentEventMutation) ClearTaskID

func (m *AgentEventMutation) ClearTaskID()

ClearTaskID clears the value of the "task_id" field.

func (*AgentEventMutation) ClearTraceID

func (m *AgentEventMutation) ClearTraceID()

ClearTraceID clears the value of the "trace_id" field.

func (*AgentEventMutation) ClearWorkflow

func (m *AgentEventMutation) ClearWorkflow()

ClearWorkflow clears the "workflow" edge to the Workflow entity.

func (*AgentEventMutation) ClearWorkflowID

func (m *AgentEventMutation) ClearWorkflowID()

ClearWorkflowID clears the value of the "workflow_id" field.

func (*AgentEventMutation) ClearedEdges

func (m *AgentEventMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*AgentEventMutation) ClearedFields

func (m *AgentEventMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (AgentEventMutation) Client

func (m AgentEventMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*AgentEventMutation) CreatedAt

func (m *AgentEventMutation) CreatedAt() (r time.Time, exists bool)

CreatedAt returns the value of the "created_at" field in the mutation.

func (*AgentEventMutation) Data

func (m *AgentEventMutation) Data() (r map[string]interface{}, exists bool)

Data returns the value of the "data" field in the mutation.

func (*AgentEventMutation) DataCleared

func (m *AgentEventMutation) DataCleared() bool

DataCleared returns if the "data" field was cleared in this mutation.

func (*AgentEventMutation) EdgeCleared

func (m *AgentEventMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*AgentEventMutation) EventCategory

func (m *AgentEventMutation) EventCategory() (r string, exists bool)

EventCategory returns the value of the "event_category" field in the mutation.

func (*AgentEventMutation) EventType

func (m *AgentEventMutation) EventType() (r string, exists bool)

EventType returns the value of the "event_type" field in the mutation.

func (*AgentEventMutation) Field

func (m *AgentEventMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*AgentEventMutation) FieldCleared

func (m *AgentEventMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*AgentEventMutation) Fields

func (m *AgentEventMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*AgentEventMutation) ID

func (m *AgentEventMutation) ID() (id string, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*AgentEventMutation) IDs

func (m *AgentEventMutation) IDs(ctx context.Context) ([]string, error)

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*AgentEventMutation) Metadata

func (m *AgentEventMutation) Metadata() (r map[string]interface{}, exists bool)

Metadata returns the value of the "metadata" field in the mutation.

func (*AgentEventMutation) MetadataCleared

func (m *AgentEventMutation) MetadataCleared() bool

MetadataCleared returns if the "metadata" field was cleared in this mutation.

func (*AgentEventMutation) OldAgentID

func (m *AgentEventMutation) OldAgentID(ctx context.Context) (v string, err error)

OldAgentID returns the old "agent_id" field's value of the AgentEvent entity. If the AgentEvent object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentEventMutation) OldCreatedAt

func (m *AgentEventMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)

OldCreatedAt returns the old "created_at" field's value of the AgentEvent entity. If the AgentEvent object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentEventMutation) OldData

func (m *AgentEventMutation) OldData(ctx context.Context) (v map[string]interface{}, err error)

OldData returns the old "data" field's value of the AgentEvent entity. If the AgentEvent object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentEventMutation) OldEventCategory

func (m *AgentEventMutation) OldEventCategory(ctx context.Context) (v string, err error)

OldEventCategory returns the old "event_category" field's value of the AgentEvent entity. If the AgentEvent object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentEventMutation) OldEventType

func (m *AgentEventMutation) OldEventType(ctx context.Context) (v string, err error)

OldEventType returns the old "event_type" field's value of the AgentEvent entity. If the AgentEvent object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentEventMutation) OldField

func (m *AgentEventMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*AgentEventMutation) OldMetadata

func (m *AgentEventMutation) OldMetadata(ctx context.Context) (v map[string]interface{}, err error)

OldMetadata returns the old "metadata" field's value of the AgentEvent entity. If the AgentEvent object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentEventMutation) OldSeverity

func (m *AgentEventMutation) OldSeverity(ctx context.Context) (v string, err error)

OldSeverity returns the old "severity" field's value of the AgentEvent entity. If the AgentEvent object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentEventMutation) OldSource

func (m *AgentEventMutation) OldSource(ctx context.Context) (v string, err error)

OldSource returns the old "source" field's value of the AgentEvent entity. If the AgentEvent object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentEventMutation) OldSpanID

func (m *AgentEventMutation) OldSpanID(ctx context.Context) (v string, err error)

OldSpanID returns the old "span_id" field's value of the AgentEvent entity. If the AgentEvent object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentEventMutation) OldTags

func (m *AgentEventMutation) OldTags(ctx context.Context) (v []string, err error)

OldTags returns the old "tags" field's value of the AgentEvent entity. If the AgentEvent object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentEventMutation) OldTaskID

func (m *AgentEventMutation) OldTaskID(ctx context.Context) (v string, err error)

OldTaskID returns the old "task_id" field's value of the AgentEvent entity. If the AgentEvent object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentEventMutation) OldTimestamp

func (m *AgentEventMutation) OldTimestamp(ctx context.Context) (v time.Time, err error)

OldTimestamp returns the old "timestamp" field's value of the AgentEvent entity. If the AgentEvent object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentEventMutation) OldTraceID

func (m *AgentEventMutation) OldTraceID(ctx context.Context) (v string, err error)

OldTraceID returns the old "trace_id" field's value of the AgentEvent entity. If the AgentEvent object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentEventMutation) OldVersion

func (m *AgentEventMutation) OldVersion(ctx context.Context) (v string, err error)

OldVersion returns the old "version" field's value of the AgentEvent entity. If the AgentEvent object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentEventMutation) OldWorkflowID

func (m *AgentEventMutation) OldWorkflowID(ctx context.Context) (v string, err error)

OldWorkflowID returns the old "workflow_id" field's value of the AgentEvent entity. If the AgentEvent object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentEventMutation) Op

func (m *AgentEventMutation) Op() Op

Op returns the operation name.

func (*AgentEventMutation) RemovedEdges

func (m *AgentEventMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*AgentEventMutation) RemovedIDs

func (m *AgentEventMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*AgentEventMutation) ResetAgentID

func (m *AgentEventMutation) ResetAgentID()

ResetAgentID resets all changes to the "agent_id" field.

func (*AgentEventMutation) ResetCreatedAt

func (m *AgentEventMutation) ResetCreatedAt()

ResetCreatedAt resets all changes to the "created_at" field.

func (*AgentEventMutation) ResetData

func (m *AgentEventMutation) ResetData()

ResetData resets all changes to the "data" field.

func (*AgentEventMutation) ResetEdge

func (m *AgentEventMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*AgentEventMutation) ResetEventCategory

func (m *AgentEventMutation) ResetEventCategory()

ResetEventCategory resets all changes to the "event_category" field.

func (*AgentEventMutation) ResetEventType

func (m *AgentEventMutation) ResetEventType()

ResetEventType resets all changes to the "event_type" field.

func (*AgentEventMutation) ResetField

func (m *AgentEventMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*AgentEventMutation) ResetMetadata

func (m *AgentEventMutation) ResetMetadata()

ResetMetadata resets all changes to the "metadata" field.

func (*AgentEventMutation) ResetSeverity

func (m *AgentEventMutation) ResetSeverity()

ResetSeverity resets all changes to the "severity" field.

func (*AgentEventMutation) ResetSource

func (m *AgentEventMutation) ResetSource()

ResetSource resets all changes to the "source" field.

func (*AgentEventMutation) ResetSpanID

func (m *AgentEventMutation) ResetSpanID()

ResetSpanID resets all changes to the "span_id" field.

func (*AgentEventMutation) ResetTags

func (m *AgentEventMutation) ResetTags()

ResetTags resets all changes to the "tags" field.

func (*AgentEventMutation) ResetTask

func (m *AgentEventMutation) ResetTask()

ResetTask resets all changes to the "task" edge.

func (*AgentEventMutation) ResetTaskID

func (m *AgentEventMutation) ResetTaskID()

ResetTaskID resets all changes to the "task_id" field.

func (*AgentEventMutation) ResetTimestamp

func (m *AgentEventMutation) ResetTimestamp()

ResetTimestamp resets all changes to the "timestamp" field.

func (*AgentEventMutation) ResetTraceID

func (m *AgentEventMutation) ResetTraceID()

ResetTraceID resets all changes to the "trace_id" field.

func (*AgentEventMutation) ResetVersion

func (m *AgentEventMutation) ResetVersion()

ResetVersion resets all changes to the "version" field.

func (*AgentEventMutation) ResetWorkflow

func (m *AgentEventMutation) ResetWorkflow()

ResetWorkflow resets all changes to the "workflow" edge.

func (*AgentEventMutation) ResetWorkflowID

func (m *AgentEventMutation) ResetWorkflowID()

ResetWorkflowID resets all changes to the "workflow_id" field.

func (*AgentEventMutation) SetAgentID

func (m *AgentEventMutation) SetAgentID(s string)

SetAgentID sets the "agent_id" field.

func (*AgentEventMutation) SetCreatedAt

func (m *AgentEventMutation) SetCreatedAt(t time.Time)

SetCreatedAt sets the "created_at" field.

func (*AgentEventMutation) SetData

func (m *AgentEventMutation) SetData(value map[string]interface{})

SetData sets the "data" field.

func (*AgentEventMutation) SetEventCategory

func (m *AgentEventMutation) SetEventCategory(s string)

SetEventCategory sets the "event_category" field.

func (*AgentEventMutation) SetEventType

func (m *AgentEventMutation) SetEventType(s string)

SetEventType sets the "event_type" field.

func (*AgentEventMutation) SetField

func (m *AgentEventMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*AgentEventMutation) SetID

func (m *AgentEventMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of AgentEvent entities.

func (*AgentEventMutation) SetMetadata

func (m *AgentEventMutation) SetMetadata(value map[string]interface{})

SetMetadata sets the "metadata" field.

func (*AgentEventMutation) SetOp

func (m *AgentEventMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*AgentEventMutation) SetSeverity

func (m *AgentEventMutation) SetSeverity(s string)

SetSeverity sets the "severity" field.

func (*AgentEventMutation) SetSource

func (m *AgentEventMutation) SetSource(s string)

SetSource sets the "source" field.

func (*AgentEventMutation) SetSpanID

func (m *AgentEventMutation) SetSpanID(s string)

SetSpanID sets the "span_id" field.

func (*AgentEventMutation) SetTags

func (m *AgentEventMutation) SetTags(s []string)

SetTags sets the "tags" field.

func (*AgentEventMutation) SetTaskID

func (m *AgentEventMutation) SetTaskID(s string)

SetTaskID sets the "task_id" field.

func (*AgentEventMutation) SetTimestamp

func (m *AgentEventMutation) SetTimestamp(t time.Time)

SetTimestamp sets the "timestamp" field.

func (*AgentEventMutation) SetTraceID

func (m *AgentEventMutation) SetTraceID(s string)

SetTraceID sets the "trace_id" field.

func (*AgentEventMutation) SetVersion

func (m *AgentEventMutation) SetVersion(s string)

SetVersion sets the "version" field.

func (*AgentEventMutation) SetWorkflowID

func (m *AgentEventMutation) SetWorkflowID(s string)

SetWorkflowID sets the "workflow_id" field.

func (*AgentEventMutation) Severity

func (m *AgentEventMutation) Severity() (r string, exists bool)

Severity returns the value of the "severity" field in the mutation.

func (*AgentEventMutation) Source

func (m *AgentEventMutation) Source() (r string, exists bool)

Source returns the value of the "source" field in the mutation.

func (*AgentEventMutation) SourceCleared

func (m *AgentEventMutation) SourceCleared() bool

SourceCleared returns if the "source" field was cleared in this mutation.

func (*AgentEventMutation) SpanID

func (m *AgentEventMutation) SpanID() (r string, exists bool)

SpanID returns the value of the "span_id" field in the mutation.

func (*AgentEventMutation) SpanIDCleared

func (m *AgentEventMutation) SpanIDCleared() bool

SpanIDCleared returns if the "span_id" field was cleared in this mutation.

func (*AgentEventMutation) Tags

func (m *AgentEventMutation) Tags() (r []string, exists bool)

Tags returns the value of the "tags" field in the mutation.

func (*AgentEventMutation) TagsCleared

func (m *AgentEventMutation) TagsCleared() bool

TagsCleared returns if the "tags" field was cleared in this mutation.

func (*AgentEventMutation) TaskCleared

func (m *AgentEventMutation) TaskCleared() bool

TaskCleared reports if the "task" edge to the AgentTask entity was cleared.

func (*AgentEventMutation) TaskID

func (m *AgentEventMutation) TaskID() (r string, exists bool)

TaskID returns the value of the "task_id" field in the mutation.

func (*AgentEventMutation) TaskIDCleared

func (m *AgentEventMutation) TaskIDCleared() bool

TaskIDCleared returns if the "task_id" field was cleared in this mutation.

func (*AgentEventMutation) TaskIDs

func (m *AgentEventMutation) TaskIDs() (ids []string)

TaskIDs returns the "task" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use TaskID instead. It exists only for internal usage by the builders.

func (*AgentEventMutation) Timestamp

func (m *AgentEventMutation) Timestamp() (r time.Time, exists bool)

Timestamp returns the value of the "timestamp" field in the mutation.

func (*AgentEventMutation) TraceID

func (m *AgentEventMutation) TraceID() (r string, exists bool)

TraceID returns the value of the "trace_id" field in the mutation.

func (*AgentEventMutation) TraceIDCleared

func (m *AgentEventMutation) TraceIDCleared() bool

TraceIDCleared returns if the "trace_id" field was cleared in this mutation.

func (AgentEventMutation) Tx

func (m AgentEventMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*AgentEventMutation) Type

func (m *AgentEventMutation) Type() string

Type returns the node type of this mutation (AgentEvent).

func (*AgentEventMutation) Version

func (m *AgentEventMutation) Version() (r string, exists bool)

Version returns the value of the "version" field in the mutation.

func (*AgentEventMutation) Where

func (m *AgentEventMutation) Where(ps ...predicate.AgentEvent)

Where appends a list predicates to the AgentEventMutation builder.

func (*AgentEventMutation) WhereP

func (m *AgentEventMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the AgentEventMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

func (*AgentEventMutation) WorkflowCleared

func (m *AgentEventMutation) WorkflowCleared() bool

WorkflowCleared reports if the "workflow" edge to the Workflow entity was cleared.

func (*AgentEventMutation) WorkflowID

func (m *AgentEventMutation) WorkflowID() (r string, exists bool)

WorkflowID returns the value of the "workflow_id" field in the mutation.

func (*AgentEventMutation) WorkflowIDCleared

func (m *AgentEventMutation) WorkflowIDCleared() bool

WorkflowIDCleared returns if the "workflow_id" field was cleared in this mutation.

func (*AgentEventMutation) WorkflowIDs

func (m *AgentEventMutation) WorkflowIDs() (ids []string)

WorkflowIDs returns the "workflow" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use WorkflowID instead. It exists only for internal usage by the builders.

type AgentEventQuery

type AgentEventQuery struct {
	// contains filtered or unexported fields
}

AgentEventQuery is the builder for querying AgentEvent entities.

func (*AgentEventQuery) Aggregate

func (aeq *AgentEventQuery) Aggregate(fns ...AggregateFunc) *AgentEventSelect

Aggregate returns a AgentEventSelect configured with the given aggregations.

func (*AgentEventQuery) All

func (aeq *AgentEventQuery) All(ctx context.Context) ([]*AgentEvent, error)

All executes the query and returns a list of AgentEvents.

func (*AgentEventQuery) AllX

func (aeq *AgentEventQuery) AllX(ctx context.Context) []*AgentEvent

AllX is like All, but panics if an error occurs.

func (*AgentEventQuery) Clone

func (aeq *AgentEventQuery) Clone() *AgentEventQuery

Clone returns a duplicate of the AgentEventQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*AgentEventQuery) Count

func (aeq *AgentEventQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*AgentEventQuery) CountX

func (aeq *AgentEventQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*AgentEventQuery) Exist

func (aeq *AgentEventQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*AgentEventQuery) ExistX

func (aeq *AgentEventQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*AgentEventQuery) First

func (aeq *AgentEventQuery) First(ctx context.Context) (*AgentEvent, error)

First returns the first AgentEvent entity from the query. Returns a *NotFoundError when no AgentEvent was found.

func (*AgentEventQuery) FirstID

func (aeq *AgentEventQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first AgentEvent ID from the query. Returns a *NotFoundError when no AgentEvent ID was found.

func (*AgentEventQuery) FirstIDX

func (aeq *AgentEventQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*AgentEventQuery) FirstX

func (aeq *AgentEventQuery) FirstX(ctx context.Context) *AgentEvent

FirstX is like First, but panics if an error occurs.

func (*AgentEventQuery) GroupBy

func (aeq *AgentEventQuery) GroupBy(field string, fields ...string) *AgentEventGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	EventType string `json:"event_type,omitempty"`
	Count int `json:"count,omitempty"`
}

client.AgentEvent.Query().
	GroupBy(agentevent.FieldEventType).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*AgentEventQuery) IDs

func (aeq *AgentEventQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of AgentEvent IDs.

func (*AgentEventQuery) IDsX

func (aeq *AgentEventQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*AgentEventQuery) Limit

func (aeq *AgentEventQuery) Limit(limit int) *AgentEventQuery

Limit the number of records to be returned by this query.

func (*AgentEventQuery) Offset

func (aeq *AgentEventQuery) Offset(offset int) *AgentEventQuery

Offset to start from.

func (*AgentEventQuery) Only

func (aeq *AgentEventQuery) Only(ctx context.Context) (*AgentEvent, error)

Only returns a single AgentEvent entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one AgentEvent entity is found. Returns a *NotFoundError when no AgentEvent entities are found.

func (*AgentEventQuery) OnlyID

func (aeq *AgentEventQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only AgentEvent ID in the query. Returns a *NotSingularError when more than one AgentEvent ID is found. Returns a *NotFoundError when no entities are found.

func (*AgentEventQuery) OnlyIDX

func (aeq *AgentEventQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*AgentEventQuery) OnlyX

func (aeq *AgentEventQuery) OnlyX(ctx context.Context) *AgentEvent

OnlyX is like Only, but panics if an error occurs.

func (*AgentEventQuery) Order

Order specifies how the records should be ordered.

func (*AgentEventQuery) QueryTask

func (aeq *AgentEventQuery) QueryTask() *AgentTaskQuery

QueryTask chains the current query on the "task" edge.

func (*AgentEventQuery) QueryWorkflow

func (aeq *AgentEventQuery) QueryWorkflow() *WorkflowQuery

QueryWorkflow chains the current query on the "workflow" edge.

func (*AgentEventQuery) Select

func (aeq *AgentEventQuery) Select(fields ...string) *AgentEventSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	EventType string `json:"event_type,omitempty"`
}

client.AgentEvent.Query().
	Select(agentevent.FieldEventType).
	Scan(ctx, &v)

func (*AgentEventQuery) Unique

func (aeq *AgentEventQuery) Unique(unique bool) *AgentEventQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*AgentEventQuery) Where

Where adds a new predicate for the AgentEventQuery builder.

func (*AgentEventQuery) WithTask

func (aeq *AgentEventQuery) WithTask(opts ...func(*AgentTaskQuery)) *AgentEventQuery

WithTask tells the query-builder to eager-load the nodes that are connected to the "task" edge. The optional arguments are used to configure the query builder of the edge.

func (*AgentEventQuery) WithWorkflow

func (aeq *AgentEventQuery) WithWorkflow(opts ...func(*WorkflowQuery)) *AgentEventQuery

WithWorkflow tells the query-builder to eager-load the nodes that are connected to the "workflow" edge. The optional arguments are used to configure the query builder of the edge.

type AgentEventSelect

type AgentEventSelect struct {
	*AgentEventQuery
	// contains filtered or unexported fields
}

AgentEventSelect is the builder for selecting fields of AgentEvent entities.

func (*AgentEventSelect) Aggregate

func (aes *AgentEventSelect) Aggregate(fns ...AggregateFunc) *AgentEventSelect

Aggregate adds the given aggregation functions to the selector query.

func (*AgentEventSelect) Bool

func (s *AgentEventSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*AgentEventSelect) BoolX

func (s *AgentEventSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*AgentEventSelect) Bools

func (s *AgentEventSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*AgentEventSelect) BoolsX

func (s *AgentEventSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*AgentEventSelect) Float64

func (s *AgentEventSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*AgentEventSelect) Float64X

func (s *AgentEventSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*AgentEventSelect) Float64s

func (s *AgentEventSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*AgentEventSelect) Float64sX

func (s *AgentEventSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*AgentEventSelect) Int

func (s *AgentEventSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*AgentEventSelect) IntX

func (s *AgentEventSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*AgentEventSelect) Ints

func (s *AgentEventSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*AgentEventSelect) IntsX

func (s *AgentEventSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*AgentEventSelect) Scan

func (aes *AgentEventSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*AgentEventSelect) ScanX

func (s *AgentEventSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*AgentEventSelect) String

func (s *AgentEventSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*AgentEventSelect) StringX

func (s *AgentEventSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*AgentEventSelect) Strings

func (s *AgentEventSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*AgentEventSelect) StringsX

func (s *AgentEventSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type AgentEventUpdate

type AgentEventUpdate struct {
	// contains filtered or unexported fields
}

AgentEventUpdate is the builder for updating AgentEvent entities.

func (*AgentEventUpdate) AppendTags

func (aeu *AgentEventUpdate) AppendTags(s []string) *AgentEventUpdate

AppendTags appends s to the "tags" field.

func (*AgentEventUpdate) ClearAgentID

func (aeu *AgentEventUpdate) ClearAgentID() *AgentEventUpdate

ClearAgentID clears the value of the "agent_id" field.

func (*AgentEventUpdate) ClearData

func (aeu *AgentEventUpdate) ClearData() *AgentEventUpdate

ClearData clears the value of the "data" field.

func (*AgentEventUpdate) ClearMetadata

func (aeu *AgentEventUpdate) ClearMetadata() *AgentEventUpdate

ClearMetadata clears the value of the "metadata" field.

func (*AgentEventUpdate) ClearSource

func (aeu *AgentEventUpdate) ClearSource() *AgentEventUpdate

ClearSource clears the value of the "source" field.

func (*AgentEventUpdate) ClearSpanID

func (aeu *AgentEventUpdate) ClearSpanID() *AgentEventUpdate

ClearSpanID clears the value of the "span_id" field.

func (*AgentEventUpdate) ClearTags

func (aeu *AgentEventUpdate) ClearTags() *AgentEventUpdate

ClearTags clears the value of the "tags" field.

func (*AgentEventUpdate) ClearTask

func (aeu *AgentEventUpdate) ClearTask() *AgentEventUpdate

ClearTask clears the "task" edge to the AgentTask entity.

func (*AgentEventUpdate) ClearTaskID

func (aeu *AgentEventUpdate) ClearTaskID() *AgentEventUpdate

ClearTaskID clears the value of the "task_id" field.

func (*AgentEventUpdate) ClearTraceID

func (aeu *AgentEventUpdate) ClearTraceID() *AgentEventUpdate

ClearTraceID clears the value of the "trace_id" field.

func (*AgentEventUpdate) ClearWorkflow

func (aeu *AgentEventUpdate) ClearWorkflow() *AgentEventUpdate

ClearWorkflow clears the "workflow" edge to the Workflow entity.

func (*AgentEventUpdate) ClearWorkflowID

func (aeu *AgentEventUpdate) ClearWorkflowID() *AgentEventUpdate

ClearWorkflowID clears the value of the "workflow_id" field.

func (*AgentEventUpdate) Exec

func (aeu *AgentEventUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*AgentEventUpdate) ExecX

func (aeu *AgentEventUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*AgentEventUpdate) Mutation

func (aeu *AgentEventUpdate) Mutation() *AgentEventMutation

Mutation returns the AgentEventMutation object of the builder.

func (*AgentEventUpdate) Save

func (aeu *AgentEventUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*AgentEventUpdate) SaveX

func (aeu *AgentEventUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*AgentEventUpdate) SetAgentID

func (aeu *AgentEventUpdate) SetAgentID(s string) *AgentEventUpdate

SetAgentID sets the "agent_id" field.

func (*AgentEventUpdate) SetData

func (aeu *AgentEventUpdate) SetData(m map[string]interface{}) *AgentEventUpdate

SetData sets the "data" field.

func (*AgentEventUpdate) SetEventCategory

func (aeu *AgentEventUpdate) SetEventCategory(s string) *AgentEventUpdate

SetEventCategory sets the "event_category" field.

func (*AgentEventUpdate) SetEventType

func (aeu *AgentEventUpdate) SetEventType(s string) *AgentEventUpdate

SetEventType sets the "event_type" field.

func (*AgentEventUpdate) SetMetadata

func (aeu *AgentEventUpdate) SetMetadata(m map[string]interface{}) *AgentEventUpdate

SetMetadata sets the "metadata" field.

func (*AgentEventUpdate) SetNillableAgentID

func (aeu *AgentEventUpdate) SetNillableAgentID(s *string) *AgentEventUpdate

SetNillableAgentID sets the "agent_id" field if the given value is not nil.

func (*AgentEventUpdate) SetNillableEventCategory

func (aeu *AgentEventUpdate) SetNillableEventCategory(s *string) *AgentEventUpdate

SetNillableEventCategory sets the "event_category" field if the given value is not nil.

func (*AgentEventUpdate) SetNillableEventType

func (aeu *AgentEventUpdate) SetNillableEventType(s *string) *AgentEventUpdate

SetNillableEventType sets the "event_type" field if the given value is not nil.

func (*AgentEventUpdate) SetNillableSeverity

func (aeu *AgentEventUpdate) SetNillableSeverity(s *string) *AgentEventUpdate

SetNillableSeverity sets the "severity" field if the given value is not nil.

func (*AgentEventUpdate) SetNillableSource

func (aeu *AgentEventUpdate) SetNillableSource(s *string) *AgentEventUpdate

SetNillableSource sets the "source" field if the given value is not nil.

func (*AgentEventUpdate) SetNillableSpanID

func (aeu *AgentEventUpdate) SetNillableSpanID(s *string) *AgentEventUpdate

SetNillableSpanID sets the "span_id" field if the given value is not nil.

func (*AgentEventUpdate) SetNillableTaskID

func (aeu *AgentEventUpdate) SetNillableTaskID(s *string) *AgentEventUpdate

SetNillableTaskID sets the "task_id" field if the given value is not nil.

func (*AgentEventUpdate) SetNillableTraceID

func (aeu *AgentEventUpdate) SetNillableTraceID(s *string) *AgentEventUpdate

SetNillableTraceID sets the "trace_id" field if the given value is not nil.

func (*AgentEventUpdate) SetNillableVersion

func (aeu *AgentEventUpdate) SetNillableVersion(s *string) *AgentEventUpdate

SetNillableVersion sets the "version" field if the given value is not nil.

func (*AgentEventUpdate) SetNillableWorkflowID

func (aeu *AgentEventUpdate) SetNillableWorkflowID(s *string) *AgentEventUpdate

SetNillableWorkflowID sets the "workflow_id" field if the given value is not nil.

func (*AgentEventUpdate) SetSeverity

func (aeu *AgentEventUpdate) SetSeverity(s string) *AgentEventUpdate

SetSeverity sets the "severity" field.

func (*AgentEventUpdate) SetSource

func (aeu *AgentEventUpdate) SetSource(s string) *AgentEventUpdate

SetSource sets the "source" field.

func (*AgentEventUpdate) SetSpanID

func (aeu *AgentEventUpdate) SetSpanID(s string) *AgentEventUpdate

SetSpanID sets the "span_id" field.

func (*AgentEventUpdate) SetTags

func (aeu *AgentEventUpdate) SetTags(s []string) *AgentEventUpdate

SetTags sets the "tags" field.

func (*AgentEventUpdate) SetTask

func (aeu *AgentEventUpdate) SetTask(a *AgentTask) *AgentEventUpdate

SetTask sets the "task" edge to the AgentTask entity.

func (*AgentEventUpdate) SetTaskID

func (aeu *AgentEventUpdate) SetTaskID(s string) *AgentEventUpdate

SetTaskID sets the "task_id" field.

func (*AgentEventUpdate) SetTraceID

func (aeu *AgentEventUpdate) SetTraceID(s string) *AgentEventUpdate

SetTraceID sets the "trace_id" field.

func (*AgentEventUpdate) SetVersion

func (aeu *AgentEventUpdate) SetVersion(s string) *AgentEventUpdate

SetVersion sets the "version" field.

func (*AgentEventUpdate) SetWorkflow

func (aeu *AgentEventUpdate) SetWorkflow(w *Workflow) *AgentEventUpdate

SetWorkflow sets the "workflow" edge to the Workflow entity.

func (*AgentEventUpdate) SetWorkflowID

func (aeu *AgentEventUpdate) SetWorkflowID(s string) *AgentEventUpdate

SetWorkflowID sets the "workflow_id" field.

func (*AgentEventUpdate) Where

Where appends a list predicates to the AgentEventUpdate builder.

type AgentEventUpdateOne

type AgentEventUpdateOne struct {
	// contains filtered or unexported fields
}

AgentEventUpdateOne is the builder for updating a single AgentEvent entity.

func (*AgentEventUpdateOne) AppendTags

func (aeuo *AgentEventUpdateOne) AppendTags(s []string) *AgentEventUpdateOne

AppendTags appends s to the "tags" field.

func (*AgentEventUpdateOne) ClearAgentID

func (aeuo *AgentEventUpdateOne) ClearAgentID() *AgentEventUpdateOne

ClearAgentID clears the value of the "agent_id" field.

func (*AgentEventUpdateOne) ClearData

func (aeuo *AgentEventUpdateOne) ClearData() *AgentEventUpdateOne

ClearData clears the value of the "data" field.

func (*AgentEventUpdateOne) ClearMetadata

func (aeuo *AgentEventUpdateOne) ClearMetadata() *AgentEventUpdateOne

ClearMetadata clears the value of the "metadata" field.

func (*AgentEventUpdateOne) ClearSource

func (aeuo *AgentEventUpdateOne) ClearSource() *AgentEventUpdateOne

ClearSource clears the value of the "source" field.

func (*AgentEventUpdateOne) ClearSpanID

func (aeuo *AgentEventUpdateOne) ClearSpanID() *AgentEventUpdateOne

ClearSpanID clears the value of the "span_id" field.

func (*AgentEventUpdateOne) ClearTags

func (aeuo *AgentEventUpdateOne) ClearTags() *AgentEventUpdateOne

ClearTags clears the value of the "tags" field.

func (*AgentEventUpdateOne) ClearTask

func (aeuo *AgentEventUpdateOne) ClearTask() *AgentEventUpdateOne

ClearTask clears the "task" edge to the AgentTask entity.

func (*AgentEventUpdateOne) ClearTaskID

func (aeuo *AgentEventUpdateOne) ClearTaskID() *AgentEventUpdateOne

ClearTaskID clears the value of the "task_id" field.

func (*AgentEventUpdateOne) ClearTraceID

func (aeuo *AgentEventUpdateOne) ClearTraceID() *AgentEventUpdateOne

ClearTraceID clears the value of the "trace_id" field.

func (*AgentEventUpdateOne) ClearWorkflow

func (aeuo *AgentEventUpdateOne) ClearWorkflow() *AgentEventUpdateOne

ClearWorkflow clears the "workflow" edge to the Workflow entity.

func (*AgentEventUpdateOne) ClearWorkflowID

func (aeuo *AgentEventUpdateOne) ClearWorkflowID() *AgentEventUpdateOne

ClearWorkflowID clears the value of the "workflow_id" field.

func (*AgentEventUpdateOne) Exec

func (aeuo *AgentEventUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*AgentEventUpdateOne) ExecX

func (aeuo *AgentEventUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*AgentEventUpdateOne) Mutation

func (aeuo *AgentEventUpdateOne) Mutation() *AgentEventMutation

Mutation returns the AgentEventMutation object of the builder.

func (*AgentEventUpdateOne) Save

func (aeuo *AgentEventUpdateOne) Save(ctx context.Context) (*AgentEvent, error)

Save executes the query and returns the updated AgentEvent entity.

func (*AgentEventUpdateOne) SaveX

func (aeuo *AgentEventUpdateOne) SaveX(ctx context.Context) *AgentEvent

SaveX is like Save, but panics if an error occurs.

func (*AgentEventUpdateOne) Select

func (aeuo *AgentEventUpdateOne) Select(field string, fields ...string) *AgentEventUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*AgentEventUpdateOne) SetAgentID

func (aeuo *AgentEventUpdateOne) SetAgentID(s string) *AgentEventUpdateOne

SetAgentID sets the "agent_id" field.

func (*AgentEventUpdateOne) SetData

func (aeuo *AgentEventUpdateOne) SetData(m map[string]interface{}) *AgentEventUpdateOne

SetData sets the "data" field.

func (*AgentEventUpdateOne) SetEventCategory

func (aeuo *AgentEventUpdateOne) SetEventCategory(s string) *AgentEventUpdateOne

SetEventCategory sets the "event_category" field.

func (*AgentEventUpdateOne) SetEventType

func (aeuo *AgentEventUpdateOne) SetEventType(s string) *AgentEventUpdateOne

SetEventType sets the "event_type" field.

func (*AgentEventUpdateOne) SetMetadata

func (aeuo *AgentEventUpdateOne) SetMetadata(m map[string]interface{}) *AgentEventUpdateOne

SetMetadata sets the "metadata" field.

func (*AgentEventUpdateOne) SetNillableAgentID

func (aeuo *AgentEventUpdateOne) SetNillableAgentID(s *string) *AgentEventUpdateOne

SetNillableAgentID sets the "agent_id" field if the given value is not nil.

func (*AgentEventUpdateOne) SetNillableEventCategory

func (aeuo *AgentEventUpdateOne) SetNillableEventCategory(s *string) *AgentEventUpdateOne

SetNillableEventCategory sets the "event_category" field if the given value is not nil.

func (*AgentEventUpdateOne) SetNillableEventType

func (aeuo *AgentEventUpdateOne) SetNillableEventType(s *string) *AgentEventUpdateOne

SetNillableEventType sets the "event_type" field if the given value is not nil.

func (*AgentEventUpdateOne) SetNillableSeverity

func (aeuo *AgentEventUpdateOne) SetNillableSeverity(s *string) *AgentEventUpdateOne

SetNillableSeverity sets the "severity" field if the given value is not nil.

func (*AgentEventUpdateOne) SetNillableSource

func (aeuo *AgentEventUpdateOne) SetNillableSource(s *string) *AgentEventUpdateOne

SetNillableSource sets the "source" field if the given value is not nil.

func (*AgentEventUpdateOne) SetNillableSpanID

func (aeuo *AgentEventUpdateOne) SetNillableSpanID(s *string) *AgentEventUpdateOne

SetNillableSpanID sets the "span_id" field if the given value is not nil.

func (*AgentEventUpdateOne) SetNillableTaskID

func (aeuo *AgentEventUpdateOne) SetNillableTaskID(s *string) *AgentEventUpdateOne

SetNillableTaskID sets the "task_id" field if the given value is not nil.

func (*AgentEventUpdateOne) SetNillableTraceID

func (aeuo *AgentEventUpdateOne) SetNillableTraceID(s *string) *AgentEventUpdateOne

SetNillableTraceID sets the "trace_id" field if the given value is not nil.

func (*AgentEventUpdateOne) SetNillableVersion

func (aeuo *AgentEventUpdateOne) SetNillableVersion(s *string) *AgentEventUpdateOne

SetNillableVersion sets the "version" field if the given value is not nil.

func (*AgentEventUpdateOne) SetNillableWorkflowID

func (aeuo *AgentEventUpdateOne) SetNillableWorkflowID(s *string) *AgentEventUpdateOne

SetNillableWorkflowID sets the "workflow_id" field if the given value is not nil.

func (*AgentEventUpdateOne) SetSeverity

func (aeuo *AgentEventUpdateOne) SetSeverity(s string) *AgentEventUpdateOne

SetSeverity sets the "severity" field.

func (*AgentEventUpdateOne) SetSource

func (aeuo *AgentEventUpdateOne) SetSource(s string) *AgentEventUpdateOne

SetSource sets the "source" field.

func (*AgentEventUpdateOne) SetSpanID

func (aeuo *AgentEventUpdateOne) SetSpanID(s string) *AgentEventUpdateOne

SetSpanID sets the "span_id" field.

func (*AgentEventUpdateOne) SetTags

func (aeuo *AgentEventUpdateOne) SetTags(s []string) *AgentEventUpdateOne

SetTags sets the "tags" field.

func (*AgentEventUpdateOne) SetTask

SetTask sets the "task" edge to the AgentTask entity.

func (*AgentEventUpdateOne) SetTaskID

func (aeuo *AgentEventUpdateOne) SetTaskID(s string) *AgentEventUpdateOne

SetTaskID sets the "task_id" field.

func (*AgentEventUpdateOne) SetTraceID

func (aeuo *AgentEventUpdateOne) SetTraceID(s string) *AgentEventUpdateOne

SetTraceID sets the "trace_id" field.

func (*AgentEventUpdateOne) SetVersion

func (aeuo *AgentEventUpdateOne) SetVersion(s string) *AgentEventUpdateOne

SetVersion sets the "version" field.

func (*AgentEventUpdateOne) SetWorkflow

func (aeuo *AgentEventUpdateOne) SetWorkflow(w *Workflow) *AgentEventUpdateOne

SetWorkflow sets the "workflow" edge to the Workflow entity.

func (*AgentEventUpdateOne) SetWorkflowID

func (aeuo *AgentEventUpdateOne) SetWorkflowID(s string) *AgentEventUpdateOne

SetWorkflowID sets the "workflow_id" field.

func (*AgentEventUpdateOne) Where

Where appends a list predicates to the AgentEventUpdate builder.

type AgentEvents

type AgentEvents []*AgentEvent

AgentEvents is a parsable slice of AgentEvent.

type AgentHandoff

type AgentHandoff struct {

	// ID of the ent.
	// Unique handoff identifier (UUID)
	ID string `json:"id,omitempty"`
	// Parent workflow ID
	WorkflowID string `json:"workflow_id,omitempty"`
	// Agent initiating the handoff
	FromAgentID string `json:"from_agent_id,omitempty"`
	// Type of source agent
	FromAgentType string `json:"from_agent_type,omitempty"`
	// Agent receiving the handoff
	ToAgentID string `json:"to_agent_id,omitempty"`
	// Type of target agent
	ToAgentType string `json:"to_agent_type,omitempty"`
	// Type of handoff: request, response, broadcast, delegate
	HandoffType string `json:"handoff_type,omitempty"`
	// Handoff status: pending, accepted, rejected, completed, failed
	Status string `json:"status,omitempty"`
	// OpenTelemetry trace ID
	TraceID string `json:"trace_id,omitempty"`
	// Task ID in the source agent
	FromTaskID string `json:"from_task_id,omitempty"`
	// Task ID in the target agent
	ToTaskID string `json:"to_task_id,omitempty"`
	// Data being passed between agents
	Payload map[string]interface{} `json:"payload,omitempty"`
	// Additional metadata
	Metadata map[string]interface{} `json:"metadata,omitempty"`
	// Size of the payload in bytes
	PayloadSizeBytes int `json:"payload_size_bytes,omitempty"`
	// Time from handoff initiation to acceptance
	LatencyMs int64 `json:"latency_ms,omitempty"`
	// Error message if handoff failed
	ErrorMessage string `json:"error_message,omitempty"`
	// When the handoff was initiated
	InitiatedAt time.Time `json:"initiated_at,omitempty"`
	// When the handoff was accepted
	AcceptedAt *time.Time `json:"accepted_at,omitempty"`
	// When the handoff was completed
	CompletedAt *time.Time `json:"completed_at,omitempty"`
	// CreatedAt holds the value of the "created_at" field.
	CreatedAt time.Time `json:"created_at,omitempty"`
	// UpdatedAt holds the value of the "updated_at" field.
	UpdatedAt time.Time `json:"updated_at,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the AgentHandoffQuery when eager-loading is set.
	Edges AgentHandoffEdges `json:"edges"`
	// contains filtered or unexported fields
}

AgentHandoff is the model entity for the AgentHandoff schema.

func (*AgentHandoff) QueryWorkflow

func (ah *AgentHandoff) QueryWorkflow() *WorkflowQuery

QueryWorkflow queries the "workflow" edge of the AgentHandoff entity.

func (*AgentHandoff) String

func (ah *AgentHandoff) String() string

String implements the fmt.Stringer.

func (*AgentHandoff) Unwrap

func (ah *AgentHandoff) Unwrap() *AgentHandoff

Unwrap unwraps the AgentHandoff entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*AgentHandoff) Update

func (ah *AgentHandoff) Update() *AgentHandoffUpdateOne

Update returns a builder for updating this AgentHandoff. Note that you need to call AgentHandoff.Unwrap() before calling this method if this AgentHandoff was returned from a transaction, and the transaction was committed or rolled back.

func (*AgentHandoff) Value

func (ah *AgentHandoff) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the AgentHandoff. This includes values selected through modifiers, order, etc.

type AgentHandoffClient

type AgentHandoffClient struct {
	// contains filtered or unexported fields
}

AgentHandoffClient is a client for the AgentHandoff schema.

func NewAgentHandoffClient

func NewAgentHandoffClient(c config) *AgentHandoffClient

NewAgentHandoffClient returns a client for the AgentHandoff from the given config.

func (*AgentHandoffClient) Create

Create returns a builder for creating a AgentHandoff entity.

func (*AgentHandoffClient) CreateBulk

func (c *AgentHandoffClient) CreateBulk(builders ...*AgentHandoffCreate) *AgentHandoffCreateBulk

CreateBulk returns a builder for creating a bulk of AgentHandoff entities.

func (*AgentHandoffClient) Delete

Delete returns a delete builder for AgentHandoff.

func (*AgentHandoffClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*AgentHandoffClient) DeleteOneID

func (c *AgentHandoffClient) DeleteOneID(id string) *AgentHandoffDeleteOne

DeleteOneID returns a builder for deleting the given entity by its id.

func (*AgentHandoffClient) Get

Get returns a AgentHandoff entity by its id.

func (*AgentHandoffClient) GetX

GetX is like Get, but panics if an error occurs.

func (*AgentHandoffClient) Hooks

func (c *AgentHandoffClient) Hooks() []Hook

Hooks returns the client hooks.

func (*AgentHandoffClient) Intercept

func (c *AgentHandoffClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `agenthandoff.Intercept(f(g(h())))`.

func (*AgentHandoffClient) Interceptors

func (c *AgentHandoffClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*AgentHandoffClient) MapCreateBulk

func (c *AgentHandoffClient) MapCreateBulk(slice any, setFunc func(*AgentHandoffCreate, int)) *AgentHandoffCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*AgentHandoffClient) Query

Query returns a query builder for AgentHandoff.

func (*AgentHandoffClient) QueryWorkflow

func (c *AgentHandoffClient) QueryWorkflow(ah *AgentHandoff) *WorkflowQuery

QueryWorkflow queries the workflow edge of a AgentHandoff.

func (*AgentHandoffClient) Update

Update returns an update builder for AgentHandoff.

func (*AgentHandoffClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*AgentHandoffClient) UpdateOneID

func (c *AgentHandoffClient) UpdateOneID(id string) *AgentHandoffUpdateOne

UpdateOneID returns an update builder for the given id.

func (*AgentHandoffClient) Use

func (c *AgentHandoffClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `agenthandoff.Hooks(f(g(h())))`.

type AgentHandoffCreate

type AgentHandoffCreate struct {
	// contains filtered or unexported fields
}

AgentHandoffCreate is the builder for creating a AgentHandoff entity.

func (*AgentHandoffCreate) Exec

func (ahc *AgentHandoffCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*AgentHandoffCreate) ExecX

func (ahc *AgentHandoffCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*AgentHandoffCreate) Mutation

func (ahc *AgentHandoffCreate) Mutation() *AgentHandoffMutation

Mutation returns the AgentHandoffMutation object of the builder.

func (*AgentHandoffCreate) Save

Save creates the AgentHandoff in the database.

func (*AgentHandoffCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*AgentHandoffCreate) SetAcceptedAt

func (ahc *AgentHandoffCreate) SetAcceptedAt(t time.Time) *AgentHandoffCreate

SetAcceptedAt sets the "accepted_at" field.

func (*AgentHandoffCreate) SetCompletedAt

func (ahc *AgentHandoffCreate) SetCompletedAt(t time.Time) *AgentHandoffCreate

SetCompletedAt sets the "completed_at" field.

func (*AgentHandoffCreate) SetCreatedAt

func (ahc *AgentHandoffCreate) SetCreatedAt(t time.Time) *AgentHandoffCreate

SetCreatedAt sets the "created_at" field.

func (*AgentHandoffCreate) SetErrorMessage

func (ahc *AgentHandoffCreate) SetErrorMessage(s string) *AgentHandoffCreate

SetErrorMessage sets the "error_message" field.

func (*AgentHandoffCreate) SetFromAgentID

func (ahc *AgentHandoffCreate) SetFromAgentID(s string) *AgentHandoffCreate

SetFromAgentID sets the "from_agent_id" field.

func (*AgentHandoffCreate) SetFromAgentType

func (ahc *AgentHandoffCreate) SetFromAgentType(s string) *AgentHandoffCreate

SetFromAgentType sets the "from_agent_type" field.

func (*AgentHandoffCreate) SetFromTaskID

func (ahc *AgentHandoffCreate) SetFromTaskID(s string) *AgentHandoffCreate

SetFromTaskID sets the "from_task_id" field.

func (*AgentHandoffCreate) SetHandoffType

func (ahc *AgentHandoffCreate) SetHandoffType(s string) *AgentHandoffCreate

SetHandoffType sets the "handoff_type" field.

func (*AgentHandoffCreate) SetID

SetID sets the "id" field.

func (*AgentHandoffCreate) SetInitiatedAt

func (ahc *AgentHandoffCreate) SetInitiatedAt(t time.Time) *AgentHandoffCreate

SetInitiatedAt sets the "initiated_at" field.

func (*AgentHandoffCreate) SetLatencyMs

func (ahc *AgentHandoffCreate) SetLatencyMs(i int64) *AgentHandoffCreate

SetLatencyMs sets the "latency_ms" field.

func (*AgentHandoffCreate) SetMetadata

func (ahc *AgentHandoffCreate) SetMetadata(m map[string]interface{}) *AgentHandoffCreate

SetMetadata sets the "metadata" field.

func (*AgentHandoffCreate) SetNillableAcceptedAt

func (ahc *AgentHandoffCreate) SetNillableAcceptedAt(t *time.Time) *AgentHandoffCreate

SetNillableAcceptedAt sets the "accepted_at" field if the given value is not nil.

func (*AgentHandoffCreate) SetNillableCompletedAt

func (ahc *AgentHandoffCreate) SetNillableCompletedAt(t *time.Time) *AgentHandoffCreate

SetNillableCompletedAt sets the "completed_at" field if the given value is not nil.

func (*AgentHandoffCreate) SetNillableCreatedAt

func (ahc *AgentHandoffCreate) SetNillableCreatedAt(t *time.Time) *AgentHandoffCreate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*AgentHandoffCreate) SetNillableErrorMessage

func (ahc *AgentHandoffCreate) SetNillableErrorMessage(s *string) *AgentHandoffCreate

SetNillableErrorMessage sets the "error_message" field if the given value is not nil.

func (*AgentHandoffCreate) SetNillableFromAgentType

func (ahc *AgentHandoffCreate) SetNillableFromAgentType(s *string) *AgentHandoffCreate

SetNillableFromAgentType sets the "from_agent_type" field if the given value is not nil.

func (*AgentHandoffCreate) SetNillableFromTaskID

func (ahc *AgentHandoffCreate) SetNillableFromTaskID(s *string) *AgentHandoffCreate

SetNillableFromTaskID sets the "from_task_id" field if the given value is not nil.

func (*AgentHandoffCreate) SetNillableHandoffType

func (ahc *AgentHandoffCreate) SetNillableHandoffType(s *string) *AgentHandoffCreate

SetNillableHandoffType sets the "handoff_type" field if the given value is not nil.

func (*AgentHandoffCreate) SetNillableInitiatedAt

func (ahc *AgentHandoffCreate) SetNillableInitiatedAt(t *time.Time) *AgentHandoffCreate

SetNillableInitiatedAt sets the "initiated_at" field if the given value is not nil.

func (*AgentHandoffCreate) SetNillableLatencyMs

func (ahc *AgentHandoffCreate) SetNillableLatencyMs(i *int64) *AgentHandoffCreate

SetNillableLatencyMs sets the "latency_ms" field if the given value is not nil.

func (*AgentHandoffCreate) SetNillablePayloadSizeBytes

func (ahc *AgentHandoffCreate) SetNillablePayloadSizeBytes(i *int) *AgentHandoffCreate

SetNillablePayloadSizeBytes sets the "payload_size_bytes" field if the given value is not nil.

func (*AgentHandoffCreate) SetNillableStatus

func (ahc *AgentHandoffCreate) SetNillableStatus(s *string) *AgentHandoffCreate

SetNillableStatus sets the "status" field if the given value is not nil.

func (*AgentHandoffCreate) SetNillableToAgentType

func (ahc *AgentHandoffCreate) SetNillableToAgentType(s *string) *AgentHandoffCreate

SetNillableToAgentType sets the "to_agent_type" field if the given value is not nil.

func (*AgentHandoffCreate) SetNillableToTaskID

func (ahc *AgentHandoffCreate) SetNillableToTaskID(s *string) *AgentHandoffCreate

SetNillableToTaskID sets the "to_task_id" field if the given value is not nil.

func (*AgentHandoffCreate) SetNillableTraceID

func (ahc *AgentHandoffCreate) SetNillableTraceID(s *string) *AgentHandoffCreate

SetNillableTraceID sets the "trace_id" field if the given value is not nil.

func (*AgentHandoffCreate) SetNillableUpdatedAt

func (ahc *AgentHandoffCreate) SetNillableUpdatedAt(t *time.Time) *AgentHandoffCreate

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*AgentHandoffCreate) SetNillableWorkflowID

func (ahc *AgentHandoffCreate) SetNillableWorkflowID(s *string) *AgentHandoffCreate

SetNillableWorkflowID sets the "workflow_id" field if the given value is not nil.

func (*AgentHandoffCreate) SetPayload

func (ahc *AgentHandoffCreate) SetPayload(m map[string]interface{}) *AgentHandoffCreate

SetPayload sets the "payload" field.

func (*AgentHandoffCreate) SetPayloadSizeBytes

func (ahc *AgentHandoffCreate) SetPayloadSizeBytes(i int) *AgentHandoffCreate

SetPayloadSizeBytes sets the "payload_size_bytes" field.

func (*AgentHandoffCreate) SetStatus

func (ahc *AgentHandoffCreate) SetStatus(s string) *AgentHandoffCreate

SetStatus sets the "status" field.

func (*AgentHandoffCreate) SetToAgentID

func (ahc *AgentHandoffCreate) SetToAgentID(s string) *AgentHandoffCreate

SetToAgentID sets the "to_agent_id" field.

func (*AgentHandoffCreate) SetToAgentType

func (ahc *AgentHandoffCreate) SetToAgentType(s string) *AgentHandoffCreate

SetToAgentType sets the "to_agent_type" field.

func (*AgentHandoffCreate) SetToTaskID

func (ahc *AgentHandoffCreate) SetToTaskID(s string) *AgentHandoffCreate

SetToTaskID sets the "to_task_id" field.

func (*AgentHandoffCreate) SetTraceID

func (ahc *AgentHandoffCreate) SetTraceID(s string) *AgentHandoffCreate

SetTraceID sets the "trace_id" field.

func (*AgentHandoffCreate) SetUpdatedAt

func (ahc *AgentHandoffCreate) SetUpdatedAt(t time.Time) *AgentHandoffCreate

SetUpdatedAt sets the "updated_at" field.

func (*AgentHandoffCreate) SetWorkflow

func (ahc *AgentHandoffCreate) SetWorkflow(w *Workflow) *AgentHandoffCreate

SetWorkflow sets the "workflow" edge to the Workflow entity.

func (*AgentHandoffCreate) SetWorkflowID

func (ahc *AgentHandoffCreate) SetWorkflowID(s string) *AgentHandoffCreate

SetWorkflowID sets the "workflow_id" field.

type AgentHandoffCreateBulk

type AgentHandoffCreateBulk struct {
	// contains filtered or unexported fields
}

AgentHandoffCreateBulk is the builder for creating many AgentHandoff entities in bulk.

func (*AgentHandoffCreateBulk) Exec

func (ahcb *AgentHandoffCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*AgentHandoffCreateBulk) ExecX

func (ahcb *AgentHandoffCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*AgentHandoffCreateBulk) Save

Save creates the AgentHandoff entities in the database.

func (*AgentHandoffCreateBulk) SaveX

func (ahcb *AgentHandoffCreateBulk) SaveX(ctx context.Context) []*AgentHandoff

SaveX is like Save, but panics if an error occurs.

type AgentHandoffDelete

type AgentHandoffDelete struct {
	// contains filtered or unexported fields
}

AgentHandoffDelete is the builder for deleting a AgentHandoff entity.

func (*AgentHandoffDelete) Exec

func (ahd *AgentHandoffDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*AgentHandoffDelete) ExecX

func (ahd *AgentHandoffDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*AgentHandoffDelete) Where

Where appends a list predicates to the AgentHandoffDelete builder.

type AgentHandoffDeleteOne

type AgentHandoffDeleteOne struct {
	// contains filtered or unexported fields
}

AgentHandoffDeleteOne is the builder for deleting a single AgentHandoff entity.

func (*AgentHandoffDeleteOne) Exec

func (ahdo *AgentHandoffDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*AgentHandoffDeleteOne) ExecX

func (ahdo *AgentHandoffDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*AgentHandoffDeleteOne) Where

Where appends a list predicates to the AgentHandoffDelete builder.

type AgentHandoffEdges

type AgentHandoffEdges struct {
	// Workflow holds the value of the workflow edge.
	Workflow *Workflow `json:"workflow,omitempty"`
	// contains filtered or unexported fields
}

AgentHandoffEdges holds the relations/edges for other nodes in the graph.

func (AgentHandoffEdges) WorkflowOrErr

func (e AgentHandoffEdges) WorkflowOrErr() (*Workflow, error)

WorkflowOrErr returns the Workflow value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

type AgentHandoffGroupBy

type AgentHandoffGroupBy struct {
	// contains filtered or unexported fields
}

AgentHandoffGroupBy is the group-by builder for AgentHandoff entities.

func (*AgentHandoffGroupBy) Aggregate

func (ahgb *AgentHandoffGroupBy) Aggregate(fns ...AggregateFunc) *AgentHandoffGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*AgentHandoffGroupBy) Bool

func (s *AgentHandoffGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*AgentHandoffGroupBy) BoolX

func (s *AgentHandoffGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*AgentHandoffGroupBy) Bools

func (s *AgentHandoffGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*AgentHandoffGroupBy) BoolsX

func (s *AgentHandoffGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*AgentHandoffGroupBy) Float64

func (s *AgentHandoffGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*AgentHandoffGroupBy) Float64X

func (s *AgentHandoffGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*AgentHandoffGroupBy) Float64s

func (s *AgentHandoffGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*AgentHandoffGroupBy) Float64sX

func (s *AgentHandoffGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*AgentHandoffGroupBy) Int

func (s *AgentHandoffGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*AgentHandoffGroupBy) IntX

func (s *AgentHandoffGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*AgentHandoffGroupBy) Ints

func (s *AgentHandoffGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*AgentHandoffGroupBy) IntsX

func (s *AgentHandoffGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*AgentHandoffGroupBy) Scan

func (ahgb *AgentHandoffGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*AgentHandoffGroupBy) ScanX

func (s *AgentHandoffGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*AgentHandoffGroupBy) String

func (s *AgentHandoffGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*AgentHandoffGroupBy) StringX

func (s *AgentHandoffGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*AgentHandoffGroupBy) Strings

func (s *AgentHandoffGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*AgentHandoffGroupBy) StringsX

func (s *AgentHandoffGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type AgentHandoffMutation

type AgentHandoffMutation struct {
	// contains filtered or unexported fields
}

AgentHandoffMutation represents an operation that mutates the AgentHandoff nodes in the graph.

func (*AgentHandoffMutation) AcceptedAt

func (m *AgentHandoffMutation) AcceptedAt() (r time.Time, exists bool)

AcceptedAt returns the value of the "accepted_at" field in the mutation.

func (*AgentHandoffMutation) AcceptedAtCleared

func (m *AgentHandoffMutation) AcceptedAtCleared() bool

AcceptedAtCleared returns if the "accepted_at" field was cleared in this mutation.

func (*AgentHandoffMutation) AddField

func (m *AgentHandoffMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*AgentHandoffMutation) AddLatencyMs

func (m *AgentHandoffMutation) AddLatencyMs(i int64)

AddLatencyMs adds i to the "latency_ms" field.

func (*AgentHandoffMutation) AddPayloadSizeBytes

func (m *AgentHandoffMutation) AddPayloadSizeBytes(i int)

AddPayloadSizeBytes adds i to the "payload_size_bytes" field.

func (*AgentHandoffMutation) AddedEdges

func (m *AgentHandoffMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*AgentHandoffMutation) AddedField

func (m *AgentHandoffMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*AgentHandoffMutation) AddedFields

func (m *AgentHandoffMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*AgentHandoffMutation) AddedIDs

func (m *AgentHandoffMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*AgentHandoffMutation) AddedLatencyMs

func (m *AgentHandoffMutation) AddedLatencyMs() (r int64, exists bool)

AddedLatencyMs returns the value that was added to the "latency_ms" field in this mutation.

func (*AgentHandoffMutation) AddedPayloadSizeBytes

func (m *AgentHandoffMutation) AddedPayloadSizeBytes() (r int, exists bool)

AddedPayloadSizeBytes returns the value that was added to the "payload_size_bytes" field in this mutation.

func (*AgentHandoffMutation) ClearAcceptedAt

func (m *AgentHandoffMutation) ClearAcceptedAt()

ClearAcceptedAt clears the value of the "accepted_at" field.

func (*AgentHandoffMutation) ClearCompletedAt

func (m *AgentHandoffMutation) ClearCompletedAt()

ClearCompletedAt clears the value of the "completed_at" field.

func (*AgentHandoffMutation) ClearEdge

func (m *AgentHandoffMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*AgentHandoffMutation) ClearErrorMessage

func (m *AgentHandoffMutation) ClearErrorMessage()

ClearErrorMessage clears the value of the "error_message" field.

func (*AgentHandoffMutation) ClearField

func (m *AgentHandoffMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*AgentHandoffMutation) ClearFromAgentType

func (m *AgentHandoffMutation) ClearFromAgentType()

ClearFromAgentType clears the value of the "from_agent_type" field.

func (*AgentHandoffMutation) ClearFromTaskID

func (m *AgentHandoffMutation) ClearFromTaskID()

ClearFromTaskID clears the value of the "from_task_id" field.

func (*AgentHandoffMutation) ClearLatencyMs

func (m *AgentHandoffMutation) ClearLatencyMs()

ClearLatencyMs clears the value of the "latency_ms" field.

func (*AgentHandoffMutation) ClearMetadata

func (m *AgentHandoffMutation) ClearMetadata()

ClearMetadata clears the value of the "metadata" field.

func (*AgentHandoffMutation) ClearPayload

func (m *AgentHandoffMutation) ClearPayload()

ClearPayload clears the value of the "payload" field.

func (*AgentHandoffMutation) ClearToAgentType

func (m *AgentHandoffMutation) ClearToAgentType()

ClearToAgentType clears the value of the "to_agent_type" field.

func (*AgentHandoffMutation) ClearToTaskID

func (m *AgentHandoffMutation) ClearToTaskID()

ClearToTaskID clears the value of the "to_task_id" field.

func (*AgentHandoffMutation) ClearTraceID

func (m *AgentHandoffMutation) ClearTraceID()

ClearTraceID clears the value of the "trace_id" field.

func (*AgentHandoffMutation) ClearWorkflow

func (m *AgentHandoffMutation) ClearWorkflow()

ClearWorkflow clears the "workflow" edge to the Workflow entity.

func (*AgentHandoffMutation) ClearWorkflowID

func (m *AgentHandoffMutation) ClearWorkflowID()

ClearWorkflowID clears the value of the "workflow_id" field.

func (*AgentHandoffMutation) ClearedEdges

func (m *AgentHandoffMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*AgentHandoffMutation) ClearedFields

func (m *AgentHandoffMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (AgentHandoffMutation) Client

func (m AgentHandoffMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*AgentHandoffMutation) CompletedAt

func (m *AgentHandoffMutation) CompletedAt() (r time.Time, exists bool)

CompletedAt returns the value of the "completed_at" field in the mutation.

func (*AgentHandoffMutation) CompletedAtCleared

func (m *AgentHandoffMutation) CompletedAtCleared() bool

CompletedAtCleared returns if the "completed_at" field was cleared in this mutation.

func (*AgentHandoffMutation) CreatedAt

func (m *AgentHandoffMutation) CreatedAt() (r time.Time, exists bool)

CreatedAt returns the value of the "created_at" field in the mutation.

func (*AgentHandoffMutation) EdgeCleared

func (m *AgentHandoffMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*AgentHandoffMutation) ErrorMessage

func (m *AgentHandoffMutation) ErrorMessage() (r string, exists bool)

ErrorMessage returns the value of the "error_message" field in the mutation.

func (*AgentHandoffMutation) ErrorMessageCleared

func (m *AgentHandoffMutation) ErrorMessageCleared() bool

ErrorMessageCleared returns if the "error_message" field was cleared in this mutation.

func (*AgentHandoffMutation) Field

func (m *AgentHandoffMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*AgentHandoffMutation) FieldCleared

func (m *AgentHandoffMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*AgentHandoffMutation) Fields

func (m *AgentHandoffMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*AgentHandoffMutation) FromAgentID

func (m *AgentHandoffMutation) FromAgentID() (r string, exists bool)

FromAgentID returns the value of the "from_agent_id" field in the mutation.

func (*AgentHandoffMutation) FromAgentType

func (m *AgentHandoffMutation) FromAgentType() (r string, exists bool)

FromAgentType returns the value of the "from_agent_type" field in the mutation.

func (*AgentHandoffMutation) FromAgentTypeCleared

func (m *AgentHandoffMutation) FromAgentTypeCleared() bool

FromAgentTypeCleared returns if the "from_agent_type" field was cleared in this mutation.

func (*AgentHandoffMutation) FromTaskID

func (m *AgentHandoffMutation) FromTaskID() (r string, exists bool)

FromTaskID returns the value of the "from_task_id" field in the mutation.

func (*AgentHandoffMutation) FromTaskIDCleared

func (m *AgentHandoffMutation) FromTaskIDCleared() bool

FromTaskIDCleared returns if the "from_task_id" field was cleared in this mutation.

func (*AgentHandoffMutation) HandoffType

func (m *AgentHandoffMutation) HandoffType() (r string, exists bool)

HandoffType returns the value of the "handoff_type" field in the mutation.

func (*AgentHandoffMutation) ID

func (m *AgentHandoffMutation) ID() (id string, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*AgentHandoffMutation) IDs

func (m *AgentHandoffMutation) IDs(ctx context.Context) ([]string, error)

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*AgentHandoffMutation) InitiatedAt

func (m *AgentHandoffMutation) InitiatedAt() (r time.Time, exists bool)

InitiatedAt returns the value of the "initiated_at" field in the mutation.

func (*AgentHandoffMutation) LatencyMs

func (m *AgentHandoffMutation) LatencyMs() (r int64, exists bool)

LatencyMs returns the value of the "latency_ms" field in the mutation.

func (*AgentHandoffMutation) LatencyMsCleared

func (m *AgentHandoffMutation) LatencyMsCleared() bool

LatencyMsCleared returns if the "latency_ms" field was cleared in this mutation.

func (*AgentHandoffMutation) Metadata

func (m *AgentHandoffMutation) Metadata() (r map[string]interface{}, exists bool)

Metadata returns the value of the "metadata" field in the mutation.

func (*AgentHandoffMutation) MetadataCleared

func (m *AgentHandoffMutation) MetadataCleared() bool

MetadataCleared returns if the "metadata" field was cleared in this mutation.

func (*AgentHandoffMutation) OldAcceptedAt

func (m *AgentHandoffMutation) OldAcceptedAt(ctx context.Context) (v *time.Time, err error)

OldAcceptedAt returns the old "accepted_at" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldCompletedAt

func (m *AgentHandoffMutation) OldCompletedAt(ctx context.Context) (v *time.Time, err error)

OldCompletedAt returns the old "completed_at" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldCreatedAt

func (m *AgentHandoffMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)

OldCreatedAt returns the old "created_at" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldErrorMessage

func (m *AgentHandoffMutation) OldErrorMessage(ctx context.Context) (v string, err error)

OldErrorMessage returns the old "error_message" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldField

func (m *AgentHandoffMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*AgentHandoffMutation) OldFromAgentID

func (m *AgentHandoffMutation) OldFromAgentID(ctx context.Context) (v string, err error)

OldFromAgentID returns the old "from_agent_id" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldFromAgentType

func (m *AgentHandoffMutation) OldFromAgentType(ctx context.Context) (v string, err error)

OldFromAgentType returns the old "from_agent_type" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldFromTaskID

func (m *AgentHandoffMutation) OldFromTaskID(ctx context.Context) (v string, err error)

OldFromTaskID returns the old "from_task_id" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldHandoffType

func (m *AgentHandoffMutation) OldHandoffType(ctx context.Context) (v string, err error)

OldHandoffType returns the old "handoff_type" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldInitiatedAt

func (m *AgentHandoffMutation) OldInitiatedAt(ctx context.Context) (v time.Time, err error)

OldInitiatedAt returns the old "initiated_at" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldLatencyMs

func (m *AgentHandoffMutation) OldLatencyMs(ctx context.Context) (v int64, err error)

OldLatencyMs returns the old "latency_ms" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldMetadata

func (m *AgentHandoffMutation) OldMetadata(ctx context.Context) (v map[string]interface{}, err error)

OldMetadata returns the old "metadata" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldPayload

func (m *AgentHandoffMutation) OldPayload(ctx context.Context) (v map[string]interface{}, err error)

OldPayload returns the old "payload" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldPayloadSizeBytes

func (m *AgentHandoffMutation) OldPayloadSizeBytes(ctx context.Context) (v int, err error)

OldPayloadSizeBytes returns the old "payload_size_bytes" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldStatus

func (m *AgentHandoffMutation) OldStatus(ctx context.Context) (v string, err error)

OldStatus returns the old "status" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldToAgentID

func (m *AgentHandoffMutation) OldToAgentID(ctx context.Context) (v string, err error)

OldToAgentID returns the old "to_agent_id" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldToAgentType

func (m *AgentHandoffMutation) OldToAgentType(ctx context.Context) (v string, err error)

OldToAgentType returns the old "to_agent_type" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldToTaskID

func (m *AgentHandoffMutation) OldToTaskID(ctx context.Context) (v string, err error)

OldToTaskID returns the old "to_task_id" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldTraceID

func (m *AgentHandoffMutation) OldTraceID(ctx context.Context) (v string, err error)

OldTraceID returns the old "trace_id" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldUpdatedAt

func (m *AgentHandoffMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)

OldUpdatedAt returns the old "updated_at" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) OldWorkflowID

func (m *AgentHandoffMutation) OldWorkflowID(ctx context.Context) (v string, err error)

OldWorkflowID returns the old "workflow_id" field's value of the AgentHandoff entity. If the AgentHandoff object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentHandoffMutation) Op

func (m *AgentHandoffMutation) Op() Op

Op returns the operation name.

func (*AgentHandoffMutation) Payload

func (m *AgentHandoffMutation) Payload() (r map[string]interface{}, exists bool)

Payload returns the value of the "payload" field in the mutation.

func (*AgentHandoffMutation) PayloadCleared

func (m *AgentHandoffMutation) PayloadCleared() bool

PayloadCleared returns if the "payload" field was cleared in this mutation.

func (*AgentHandoffMutation) PayloadSizeBytes

func (m *AgentHandoffMutation) PayloadSizeBytes() (r int, exists bool)

PayloadSizeBytes returns the value of the "payload_size_bytes" field in the mutation.

func (*AgentHandoffMutation) RemovedEdges

func (m *AgentHandoffMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*AgentHandoffMutation) RemovedIDs

func (m *AgentHandoffMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*AgentHandoffMutation) ResetAcceptedAt

func (m *AgentHandoffMutation) ResetAcceptedAt()

ResetAcceptedAt resets all changes to the "accepted_at" field.

func (*AgentHandoffMutation) ResetCompletedAt

func (m *AgentHandoffMutation) ResetCompletedAt()

ResetCompletedAt resets all changes to the "completed_at" field.

func (*AgentHandoffMutation) ResetCreatedAt

func (m *AgentHandoffMutation) ResetCreatedAt()

ResetCreatedAt resets all changes to the "created_at" field.

func (*AgentHandoffMutation) ResetEdge

func (m *AgentHandoffMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*AgentHandoffMutation) ResetErrorMessage

func (m *AgentHandoffMutation) ResetErrorMessage()

ResetErrorMessage resets all changes to the "error_message" field.

func (*AgentHandoffMutation) ResetField

func (m *AgentHandoffMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*AgentHandoffMutation) ResetFromAgentID

func (m *AgentHandoffMutation) ResetFromAgentID()

ResetFromAgentID resets all changes to the "from_agent_id" field.

func (*AgentHandoffMutation) ResetFromAgentType

func (m *AgentHandoffMutation) ResetFromAgentType()

ResetFromAgentType resets all changes to the "from_agent_type" field.

func (*AgentHandoffMutation) ResetFromTaskID

func (m *AgentHandoffMutation) ResetFromTaskID()

ResetFromTaskID resets all changes to the "from_task_id" field.

func (*AgentHandoffMutation) ResetHandoffType

func (m *AgentHandoffMutation) ResetHandoffType()

ResetHandoffType resets all changes to the "handoff_type" field.

func (*AgentHandoffMutation) ResetInitiatedAt

func (m *AgentHandoffMutation) ResetInitiatedAt()

ResetInitiatedAt resets all changes to the "initiated_at" field.

func (*AgentHandoffMutation) ResetLatencyMs

func (m *AgentHandoffMutation) ResetLatencyMs()

ResetLatencyMs resets all changes to the "latency_ms" field.

func (*AgentHandoffMutation) ResetMetadata

func (m *AgentHandoffMutation) ResetMetadata()

ResetMetadata resets all changes to the "metadata" field.

func (*AgentHandoffMutation) ResetPayload

func (m *AgentHandoffMutation) ResetPayload()

ResetPayload resets all changes to the "payload" field.

func (*AgentHandoffMutation) ResetPayloadSizeBytes

func (m *AgentHandoffMutation) ResetPayloadSizeBytes()

ResetPayloadSizeBytes resets all changes to the "payload_size_bytes" field.

func (*AgentHandoffMutation) ResetStatus

func (m *AgentHandoffMutation) ResetStatus()

ResetStatus resets all changes to the "status" field.

func (*AgentHandoffMutation) ResetToAgentID

func (m *AgentHandoffMutation) ResetToAgentID()

ResetToAgentID resets all changes to the "to_agent_id" field.

func (*AgentHandoffMutation) ResetToAgentType

func (m *AgentHandoffMutation) ResetToAgentType()

ResetToAgentType resets all changes to the "to_agent_type" field.

func (*AgentHandoffMutation) ResetToTaskID

func (m *AgentHandoffMutation) ResetToTaskID()

ResetToTaskID resets all changes to the "to_task_id" field.

func (*AgentHandoffMutation) ResetTraceID

func (m *AgentHandoffMutation) ResetTraceID()

ResetTraceID resets all changes to the "trace_id" field.

func (*AgentHandoffMutation) ResetUpdatedAt

func (m *AgentHandoffMutation) ResetUpdatedAt()

ResetUpdatedAt resets all changes to the "updated_at" field.

func (*AgentHandoffMutation) ResetWorkflow

func (m *AgentHandoffMutation) ResetWorkflow()

ResetWorkflow resets all changes to the "workflow" edge.

func (*AgentHandoffMutation) ResetWorkflowID

func (m *AgentHandoffMutation) ResetWorkflowID()

ResetWorkflowID resets all changes to the "workflow_id" field.

func (*AgentHandoffMutation) SetAcceptedAt

func (m *AgentHandoffMutation) SetAcceptedAt(t time.Time)

SetAcceptedAt sets the "accepted_at" field.

func (*AgentHandoffMutation) SetCompletedAt

func (m *AgentHandoffMutation) SetCompletedAt(t time.Time)

SetCompletedAt sets the "completed_at" field.

func (*AgentHandoffMutation) SetCreatedAt

func (m *AgentHandoffMutation) SetCreatedAt(t time.Time)

SetCreatedAt sets the "created_at" field.

func (*AgentHandoffMutation) SetErrorMessage

func (m *AgentHandoffMutation) SetErrorMessage(s string)

SetErrorMessage sets the "error_message" field.

func (*AgentHandoffMutation) SetField

func (m *AgentHandoffMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*AgentHandoffMutation) SetFromAgentID

func (m *AgentHandoffMutation) SetFromAgentID(s string)

SetFromAgentID sets the "from_agent_id" field.

func (*AgentHandoffMutation) SetFromAgentType

func (m *AgentHandoffMutation) SetFromAgentType(s string)

SetFromAgentType sets the "from_agent_type" field.

func (*AgentHandoffMutation) SetFromTaskID

func (m *AgentHandoffMutation) SetFromTaskID(s string)

SetFromTaskID sets the "from_task_id" field.

func (*AgentHandoffMutation) SetHandoffType

func (m *AgentHandoffMutation) SetHandoffType(s string)

SetHandoffType sets the "handoff_type" field.

func (*AgentHandoffMutation) SetID

func (m *AgentHandoffMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of AgentHandoff entities.

func (*AgentHandoffMutation) SetInitiatedAt

func (m *AgentHandoffMutation) SetInitiatedAt(t time.Time)

SetInitiatedAt sets the "initiated_at" field.

func (*AgentHandoffMutation) SetLatencyMs

func (m *AgentHandoffMutation) SetLatencyMs(i int64)

SetLatencyMs sets the "latency_ms" field.

func (*AgentHandoffMutation) SetMetadata

func (m *AgentHandoffMutation) SetMetadata(value map[string]interface{})

SetMetadata sets the "metadata" field.

func (*AgentHandoffMutation) SetOp

func (m *AgentHandoffMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*AgentHandoffMutation) SetPayload

func (m *AgentHandoffMutation) SetPayload(value map[string]interface{})

SetPayload sets the "payload" field.

func (*AgentHandoffMutation) SetPayloadSizeBytes

func (m *AgentHandoffMutation) SetPayloadSizeBytes(i int)

SetPayloadSizeBytes sets the "payload_size_bytes" field.

func (*AgentHandoffMutation) SetStatus

func (m *AgentHandoffMutation) SetStatus(s string)

SetStatus sets the "status" field.

func (*AgentHandoffMutation) SetToAgentID

func (m *AgentHandoffMutation) SetToAgentID(s string)

SetToAgentID sets the "to_agent_id" field.

func (*AgentHandoffMutation) SetToAgentType

func (m *AgentHandoffMutation) SetToAgentType(s string)

SetToAgentType sets the "to_agent_type" field.

func (*AgentHandoffMutation) SetToTaskID

func (m *AgentHandoffMutation) SetToTaskID(s string)

SetToTaskID sets the "to_task_id" field.

func (*AgentHandoffMutation) SetTraceID

func (m *AgentHandoffMutation) SetTraceID(s string)

SetTraceID sets the "trace_id" field.

func (*AgentHandoffMutation) SetUpdatedAt

func (m *AgentHandoffMutation) SetUpdatedAt(t time.Time)

SetUpdatedAt sets the "updated_at" field.

func (*AgentHandoffMutation) SetWorkflowID

func (m *AgentHandoffMutation) SetWorkflowID(s string)

SetWorkflowID sets the "workflow_id" field.

func (*AgentHandoffMutation) Status

func (m *AgentHandoffMutation) Status() (r string, exists bool)

Status returns the value of the "status" field in the mutation.

func (*AgentHandoffMutation) ToAgentID

func (m *AgentHandoffMutation) ToAgentID() (r string, exists bool)

ToAgentID returns the value of the "to_agent_id" field in the mutation.

func (*AgentHandoffMutation) ToAgentType

func (m *AgentHandoffMutation) ToAgentType() (r string, exists bool)

ToAgentType returns the value of the "to_agent_type" field in the mutation.

func (*AgentHandoffMutation) ToAgentTypeCleared

func (m *AgentHandoffMutation) ToAgentTypeCleared() bool

ToAgentTypeCleared returns if the "to_agent_type" field was cleared in this mutation.

func (*AgentHandoffMutation) ToTaskID

func (m *AgentHandoffMutation) ToTaskID() (r string, exists bool)

ToTaskID returns the value of the "to_task_id" field in the mutation.

func (*AgentHandoffMutation) ToTaskIDCleared

func (m *AgentHandoffMutation) ToTaskIDCleared() bool

ToTaskIDCleared returns if the "to_task_id" field was cleared in this mutation.

func (*AgentHandoffMutation) TraceID

func (m *AgentHandoffMutation) TraceID() (r string, exists bool)

TraceID returns the value of the "trace_id" field in the mutation.

func (*AgentHandoffMutation) TraceIDCleared

func (m *AgentHandoffMutation) TraceIDCleared() bool

TraceIDCleared returns if the "trace_id" field was cleared in this mutation.

func (AgentHandoffMutation) Tx

func (m AgentHandoffMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*AgentHandoffMutation) Type

func (m *AgentHandoffMutation) Type() string

Type returns the node type of this mutation (AgentHandoff).

func (*AgentHandoffMutation) UpdatedAt

func (m *AgentHandoffMutation) UpdatedAt() (r time.Time, exists bool)

UpdatedAt returns the value of the "updated_at" field in the mutation.

func (*AgentHandoffMutation) Where

Where appends a list predicates to the AgentHandoffMutation builder.

func (*AgentHandoffMutation) WhereP

func (m *AgentHandoffMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the AgentHandoffMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

func (*AgentHandoffMutation) WorkflowCleared

func (m *AgentHandoffMutation) WorkflowCleared() bool

WorkflowCleared reports if the "workflow" edge to the Workflow entity was cleared.

func (*AgentHandoffMutation) WorkflowID

func (m *AgentHandoffMutation) WorkflowID() (r string, exists bool)

WorkflowID returns the value of the "workflow_id" field in the mutation.

func (*AgentHandoffMutation) WorkflowIDCleared

func (m *AgentHandoffMutation) WorkflowIDCleared() bool

WorkflowIDCleared returns if the "workflow_id" field was cleared in this mutation.

func (*AgentHandoffMutation) WorkflowIDs

func (m *AgentHandoffMutation) WorkflowIDs() (ids []string)

WorkflowIDs returns the "workflow" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use WorkflowID instead. It exists only for internal usage by the builders.

type AgentHandoffQuery

type AgentHandoffQuery struct {
	// contains filtered or unexported fields
}

AgentHandoffQuery is the builder for querying AgentHandoff entities.

func (*AgentHandoffQuery) Aggregate

func (ahq *AgentHandoffQuery) Aggregate(fns ...AggregateFunc) *AgentHandoffSelect

Aggregate returns a AgentHandoffSelect configured with the given aggregations.

func (*AgentHandoffQuery) All

func (ahq *AgentHandoffQuery) All(ctx context.Context) ([]*AgentHandoff, error)

All executes the query and returns a list of AgentHandoffs.

func (*AgentHandoffQuery) AllX

func (ahq *AgentHandoffQuery) AllX(ctx context.Context) []*AgentHandoff

AllX is like All, but panics if an error occurs.

func (*AgentHandoffQuery) Clone

func (ahq *AgentHandoffQuery) Clone() *AgentHandoffQuery

Clone returns a duplicate of the AgentHandoffQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*AgentHandoffQuery) Count

func (ahq *AgentHandoffQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*AgentHandoffQuery) CountX

func (ahq *AgentHandoffQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*AgentHandoffQuery) Exist

func (ahq *AgentHandoffQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*AgentHandoffQuery) ExistX

func (ahq *AgentHandoffQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*AgentHandoffQuery) First

func (ahq *AgentHandoffQuery) First(ctx context.Context) (*AgentHandoff, error)

First returns the first AgentHandoff entity from the query. Returns a *NotFoundError when no AgentHandoff was found.

func (*AgentHandoffQuery) FirstID

func (ahq *AgentHandoffQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first AgentHandoff ID from the query. Returns a *NotFoundError when no AgentHandoff ID was found.

func (*AgentHandoffQuery) FirstIDX

func (ahq *AgentHandoffQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*AgentHandoffQuery) FirstX

func (ahq *AgentHandoffQuery) FirstX(ctx context.Context) *AgentHandoff

FirstX is like First, but panics if an error occurs.

func (*AgentHandoffQuery) GroupBy

func (ahq *AgentHandoffQuery) GroupBy(field string, fields ...string) *AgentHandoffGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	WorkflowID string `json:"workflow_id,omitempty"`
	Count int `json:"count,omitempty"`
}

client.AgentHandoff.Query().
	GroupBy(agenthandoff.FieldWorkflowID).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*AgentHandoffQuery) IDs

func (ahq *AgentHandoffQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of AgentHandoff IDs.

func (*AgentHandoffQuery) IDsX

func (ahq *AgentHandoffQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*AgentHandoffQuery) Limit

func (ahq *AgentHandoffQuery) Limit(limit int) *AgentHandoffQuery

Limit the number of records to be returned by this query.

func (*AgentHandoffQuery) Offset

func (ahq *AgentHandoffQuery) Offset(offset int) *AgentHandoffQuery

Offset to start from.

func (*AgentHandoffQuery) Only

func (ahq *AgentHandoffQuery) Only(ctx context.Context) (*AgentHandoff, error)

Only returns a single AgentHandoff entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one AgentHandoff entity is found. Returns a *NotFoundError when no AgentHandoff entities are found.

func (*AgentHandoffQuery) OnlyID

func (ahq *AgentHandoffQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only AgentHandoff ID in the query. Returns a *NotSingularError when more than one AgentHandoff ID is found. Returns a *NotFoundError when no entities are found.

func (*AgentHandoffQuery) OnlyIDX

func (ahq *AgentHandoffQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*AgentHandoffQuery) OnlyX

func (ahq *AgentHandoffQuery) OnlyX(ctx context.Context) *AgentHandoff

OnlyX is like Only, but panics if an error occurs.

func (*AgentHandoffQuery) Order

Order specifies how the records should be ordered.

func (*AgentHandoffQuery) QueryWorkflow

func (ahq *AgentHandoffQuery) QueryWorkflow() *WorkflowQuery

QueryWorkflow chains the current query on the "workflow" edge.

func (*AgentHandoffQuery) Select

func (ahq *AgentHandoffQuery) Select(fields ...string) *AgentHandoffSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	WorkflowID string `json:"workflow_id,omitempty"`
}

client.AgentHandoff.Query().
	Select(agenthandoff.FieldWorkflowID).
	Scan(ctx, &v)

func (*AgentHandoffQuery) Unique

func (ahq *AgentHandoffQuery) Unique(unique bool) *AgentHandoffQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*AgentHandoffQuery) Where

Where adds a new predicate for the AgentHandoffQuery builder.

func (*AgentHandoffQuery) WithWorkflow

func (ahq *AgentHandoffQuery) WithWorkflow(opts ...func(*WorkflowQuery)) *AgentHandoffQuery

WithWorkflow tells the query-builder to eager-load the nodes that are connected to the "workflow" edge. The optional arguments are used to configure the query builder of the edge.

type AgentHandoffSelect

type AgentHandoffSelect struct {
	*AgentHandoffQuery
	// contains filtered or unexported fields
}

AgentHandoffSelect is the builder for selecting fields of AgentHandoff entities.

func (*AgentHandoffSelect) Aggregate

func (ahs *AgentHandoffSelect) Aggregate(fns ...AggregateFunc) *AgentHandoffSelect

Aggregate adds the given aggregation functions to the selector query.

func (*AgentHandoffSelect) Bool

func (s *AgentHandoffSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*AgentHandoffSelect) BoolX

func (s *AgentHandoffSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*AgentHandoffSelect) Bools

func (s *AgentHandoffSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*AgentHandoffSelect) BoolsX

func (s *AgentHandoffSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*AgentHandoffSelect) Float64

func (s *AgentHandoffSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*AgentHandoffSelect) Float64X

func (s *AgentHandoffSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*AgentHandoffSelect) Float64s

func (s *AgentHandoffSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*AgentHandoffSelect) Float64sX

func (s *AgentHandoffSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*AgentHandoffSelect) Int

func (s *AgentHandoffSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*AgentHandoffSelect) IntX

func (s *AgentHandoffSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*AgentHandoffSelect) Ints

func (s *AgentHandoffSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*AgentHandoffSelect) IntsX

func (s *AgentHandoffSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*AgentHandoffSelect) Scan

func (ahs *AgentHandoffSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*AgentHandoffSelect) ScanX

func (s *AgentHandoffSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*AgentHandoffSelect) String

func (s *AgentHandoffSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*AgentHandoffSelect) StringX

func (s *AgentHandoffSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*AgentHandoffSelect) Strings

func (s *AgentHandoffSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*AgentHandoffSelect) StringsX

func (s *AgentHandoffSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type AgentHandoffUpdate

type AgentHandoffUpdate struct {
	// contains filtered or unexported fields
}

AgentHandoffUpdate is the builder for updating AgentHandoff entities.

func (*AgentHandoffUpdate) AddLatencyMs

func (ahu *AgentHandoffUpdate) AddLatencyMs(i int64) *AgentHandoffUpdate

AddLatencyMs adds i to the "latency_ms" field.

func (*AgentHandoffUpdate) AddPayloadSizeBytes

func (ahu *AgentHandoffUpdate) AddPayloadSizeBytes(i int) *AgentHandoffUpdate

AddPayloadSizeBytes adds i to the "payload_size_bytes" field.

func (*AgentHandoffUpdate) ClearAcceptedAt

func (ahu *AgentHandoffUpdate) ClearAcceptedAt() *AgentHandoffUpdate

ClearAcceptedAt clears the value of the "accepted_at" field.

func (*AgentHandoffUpdate) ClearCompletedAt

func (ahu *AgentHandoffUpdate) ClearCompletedAt() *AgentHandoffUpdate

ClearCompletedAt clears the value of the "completed_at" field.

func (*AgentHandoffUpdate) ClearErrorMessage

func (ahu *AgentHandoffUpdate) ClearErrorMessage() *AgentHandoffUpdate

ClearErrorMessage clears the value of the "error_message" field.

func (*AgentHandoffUpdate) ClearFromAgentType

func (ahu *AgentHandoffUpdate) ClearFromAgentType() *AgentHandoffUpdate

ClearFromAgentType clears the value of the "from_agent_type" field.

func (*AgentHandoffUpdate) ClearFromTaskID

func (ahu *AgentHandoffUpdate) ClearFromTaskID() *AgentHandoffUpdate

ClearFromTaskID clears the value of the "from_task_id" field.

func (*AgentHandoffUpdate) ClearLatencyMs

func (ahu *AgentHandoffUpdate) ClearLatencyMs() *AgentHandoffUpdate

ClearLatencyMs clears the value of the "latency_ms" field.

func (*AgentHandoffUpdate) ClearMetadata

func (ahu *AgentHandoffUpdate) ClearMetadata() *AgentHandoffUpdate

ClearMetadata clears the value of the "metadata" field.

func (*AgentHandoffUpdate) ClearPayload

func (ahu *AgentHandoffUpdate) ClearPayload() *AgentHandoffUpdate

ClearPayload clears the value of the "payload" field.

func (*AgentHandoffUpdate) ClearToAgentType

func (ahu *AgentHandoffUpdate) ClearToAgentType() *AgentHandoffUpdate

ClearToAgentType clears the value of the "to_agent_type" field.

func (*AgentHandoffUpdate) ClearToTaskID

func (ahu *AgentHandoffUpdate) ClearToTaskID() *AgentHandoffUpdate

ClearToTaskID clears the value of the "to_task_id" field.

func (*AgentHandoffUpdate) ClearTraceID

func (ahu *AgentHandoffUpdate) ClearTraceID() *AgentHandoffUpdate

ClearTraceID clears the value of the "trace_id" field.

func (*AgentHandoffUpdate) ClearWorkflow

func (ahu *AgentHandoffUpdate) ClearWorkflow() *AgentHandoffUpdate

ClearWorkflow clears the "workflow" edge to the Workflow entity.

func (*AgentHandoffUpdate) ClearWorkflowID

func (ahu *AgentHandoffUpdate) ClearWorkflowID() *AgentHandoffUpdate

ClearWorkflowID clears the value of the "workflow_id" field.

func (*AgentHandoffUpdate) Exec

func (ahu *AgentHandoffUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*AgentHandoffUpdate) ExecX

func (ahu *AgentHandoffUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*AgentHandoffUpdate) Mutation

func (ahu *AgentHandoffUpdate) Mutation() *AgentHandoffMutation

Mutation returns the AgentHandoffMutation object of the builder.

func (*AgentHandoffUpdate) Save

func (ahu *AgentHandoffUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*AgentHandoffUpdate) SaveX

func (ahu *AgentHandoffUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*AgentHandoffUpdate) SetAcceptedAt

func (ahu *AgentHandoffUpdate) SetAcceptedAt(t time.Time) *AgentHandoffUpdate

SetAcceptedAt sets the "accepted_at" field.

func (*AgentHandoffUpdate) SetCompletedAt

func (ahu *AgentHandoffUpdate) SetCompletedAt(t time.Time) *AgentHandoffUpdate

SetCompletedAt sets the "completed_at" field.

func (*AgentHandoffUpdate) SetErrorMessage

func (ahu *AgentHandoffUpdate) SetErrorMessage(s string) *AgentHandoffUpdate

SetErrorMessage sets the "error_message" field.

func (*AgentHandoffUpdate) SetFromAgentID

func (ahu *AgentHandoffUpdate) SetFromAgentID(s string) *AgentHandoffUpdate

SetFromAgentID sets the "from_agent_id" field.

func (*AgentHandoffUpdate) SetFromAgentType

func (ahu *AgentHandoffUpdate) SetFromAgentType(s string) *AgentHandoffUpdate

SetFromAgentType sets the "from_agent_type" field.

func (*AgentHandoffUpdate) SetFromTaskID

func (ahu *AgentHandoffUpdate) SetFromTaskID(s string) *AgentHandoffUpdate

SetFromTaskID sets the "from_task_id" field.

func (*AgentHandoffUpdate) SetHandoffType

func (ahu *AgentHandoffUpdate) SetHandoffType(s string) *AgentHandoffUpdate

SetHandoffType sets the "handoff_type" field.

func (*AgentHandoffUpdate) SetLatencyMs

func (ahu *AgentHandoffUpdate) SetLatencyMs(i int64) *AgentHandoffUpdate

SetLatencyMs sets the "latency_ms" field.

func (*AgentHandoffUpdate) SetMetadata

func (ahu *AgentHandoffUpdate) SetMetadata(m map[string]interface{}) *AgentHandoffUpdate

SetMetadata sets the "metadata" field.

func (*AgentHandoffUpdate) SetNillableAcceptedAt

func (ahu *AgentHandoffUpdate) SetNillableAcceptedAt(t *time.Time) *AgentHandoffUpdate

SetNillableAcceptedAt sets the "accepted_at" field if the given value is not nil.

func (*AgentHandoffUpdate) SetNillableCompletedAt

func (ahu *AgentHandoffUpdate) SetNillableCompletedAt(t *time.Time) *AgentHandoffUpdate

SetNillableCompletedAt sets the "completed_at" field if the given value is not nil.

func (*AgentHandoffUpdate) SetNillableErrorMessage

func (ahu *AgentHandoffUpdate) SetNillableErrorMessage(s *string) *AgentHandoffUpdate

SetNillableErrorMessage sets the "error_message" field if the given value is not nil.

func (*AgentHandoffUpdate) SetNillableFromAgentID

func (ahu *AgentHandoffUpdate) SetNillableFromAgentID(s *string) *AgentHandoffUpdate

SetNillableFromAgentID sets the "from_agent_id" field if the given value is not nil.

func (*AgentHandoffUpdate) SetNillableFromAgentType

func (ahu *AgentHandoffUpdate) SetNillableFromAgentType(s *string) *AgentHandoffUpdate

SetNillableFromAgentType sets the "from_agent_type" field if the given value is not nil.

func (*AgentHandoffUpdate) SetNillableFromTaskID

func (ahu *AgentHandoffUpdate) SetNillableFromTaskID(s *string) *AgentHandoffUpdate

SetNillableFromTaskID sets the "from_task_id" field if the given value is not nil.

func (*AgentHandoffUpdate) SetNillableHandoffType

func (ahu *AgentHandoffUpdate) SetNillableHandoffType(s *string) *AgentHandoffUpdate

SetNillableHandoffType sets the "handoff_type" field if the given value is not nil.

func (*AgentHandoffUpdate) SetNillableLatencyMs

func (ahu *AgentHandoffUpdate) SetNillableLatencyMs(i *int64) *AgentHandoffUpdate

SetNillableLatencyMs sets the "latency_ms" field if the given value is not nil.

func (*AgentHandoffUpdate) SetNillablePayloadSizeBytes

func (ahu *AgentHandoffUpdate) SetNillablePayloadSizeBytes(i *int) *AgentHandoffUpdate

SetNillablePayloadSizeBytes sets the "payload_size_bytes" field if the given value is not nil.

func (*AgentHandoffUpdate) SetNillableStatus

func (ahu *AgentHandoffUpdate) SetNillableStatus(s *string) *AgentHandoffUpdate

SetNillableStatus sets the "status" field if the given value is not nil.

func (*AgentHandoffUpdate) SetNillableToAgentID

func (ahu *AgentHandoffUpdate) SetNillableToAgentID(s *string) *AgentHandoffUpdate

SetNillableToAgentID sets the "to_agent_id" field if the given value is not nil.

func (*AgentHandoffUpdate) SetNillableToAgentType

func (ahu *AgentHandoffUpdate) SetNillableToAgentType(s *string) *AgentHandoffUpdate

SetNillableToAgentType sets the "to_agent_type" field if the given value is not nil.

func (*AgentHandoffUpdate) SetNillableToTaskID

func (ahu *AgentHandoffUpdate) SetNillableToTaskID(s *string) *AgentHandoffUpdate

SetNillableToTaskID sets the "to_task_id" field if the given value is not nil.

func (*AgentHandoffUpdate) SetNillableTraceID

func (ahu *AgentHandoffUpdate) SetNillableTraceID(s *string) *AgentHandoffUpdate

SetNillableTraceID sets the "trace_id" field if the given value is not nil.

func (*AgentHandoffUpdate) SetNillableWorkflowID

func (ahu *AgentHandoffUpdate) SetNillableWorkflowID(s *string) *AgentHandoffUpdate

SetNillableWorkflowID sets the "workflow_id" field if the given value is not nil.

func (*AgentHandoffUpdate) SetPayload

func (ahu *AgentHandoffUpdate) SetPayload(m map[string]interface{}) *AgentHandoffUpdate

SetPayload sets the "payload" field.

func (*AgentHandoffUpdate) SetPayloadSizeBytes

func (ahu *AgentHandoffUpdate) SetPayloadSizeBytes(i int) *AgentHandoffUpdate

SetPayloadSizeBytes sets the "payload_size_bytes" field.

func (*AgentHandoffUpdate) SetStatus

func (ahu *AgentHandoffUpdate) SetStatus(s string) *AgentHandoffUpdate

SetStatus sets the "status" field.

func (*AgentHandoffUpdate) SetToAgentID

func (ahu *AgentHandoffUpdate) SetToAgentID(s string) *AgentHandoffUpdate

SetToAgentID sets the "to_agent_id" field.

func (*AgentHandoffUpdate) SetToAgentType

func (ahu *AgentHandoffUpdate) SetToAgentType(s string) *AgentHandoffUpdate

SetToAgentType sets the "to_agent_type" field.

func (*AgentHandoffUpdate) SetToTaskID

func (ahu *AgentHandoffUpdate) SetToTaskID(s string) *AgentHandoffUpdate

SetToTaskID sets the "to_task_id" field.

func (*AgentHandoffUpdate) SetTraceID

func (ahu *AgentHandoffUpdate) SetTraceID(s string) *AgentHandoffUpdate

SetTraceID sets the "trace_id" field.

func (*AgentHandoffUpdate) SetUpdatedAt

func (ahu *AgentHandoffUpdate) SetUpdatedAt(t time.Time) *AgentHandoffUpdate

SetUpdatedAt sets the "updated_at" field.

func (*AgentHandoffUpdate) SetWorkflow

func (ahu *AgentHandoffUpdate) SetWorkflow(w *Workflow) *AgentHandoffUpdate

SetWorkflow sets the "workflow" edge to the Workflow entity.

func (*AgentHandoffUpdate) SetWorkflowID

func (ahu *AgentHandoffUpdate) SetWorkflowID(s string) *AgentHandoffUpdate

SetWorkflowID sets the "workflow_id" field.

func (*AgentHandoffUpdate) Where

Where appends a list predicates to the AgentHandoffUpdate builder.

type AgentHandoffUpdateOne

type AgentHandoffUpdateOne struct {
	// contains filtered or unexported fields
}

AgentHandoffUpdateOne is the builder for updating a single AgentHandoff entity.

func (*AgentHandoffUpdateOne) AddLatencyMs

func (ahuo *AgentHandoffUpdateOne) AddLatencyMs(i int64) *AgentHandoffUpdateOne

AddLatencyMs adds i to the "latency_ms" field.

func (*AgentHandoffUpdateOne) AddPayloadSizeBytes

func (ahuo *AgentHandoffUpdateOne) AddPayloadSizeBytes(i int) *AgentHandoffUpdateOne

AddPayloadSizeBytes adds i to the "payload_size_bytes" field.

func (*AgentHandoffUpdateOne) ClearAcceptedAt

func (ahuo *AgentHandoffUpdateOne) ClearAcceptedAt() *AgentHandoffUpdateOne

ClearAcceptedAt clears the value of the "accepted_at" field.

func (*AgentHandoffUpdateOne) ClearCompletedAt

func (ahuo *AgentHandoffUpdateOne) ClearCompletedAt() *AgentHandoffUpdateOne

ClearCompletedAt clears the value of the "completed_at" field.

func (*AgentHandoffUpdateOne) ClearErrorMessage

func (ahuo *AgentHandoffUpdateOne) ClearErrorMessage() *AgentHandoffUpdateOne

ClearErrorMessage clears the value of the "error_message" field.

func (*AgentHandoffUpdateOne) ClearFromAgentType

func (ahuo *AgentHandoffUpdateOne) ClearFromAgentType() *AgentHandoffUpdateOne

ClearFromAgentType clears the value of the "from_agent_type" field.

func (*AgentHandoffUpdateOne) ClearFromTaskID

func (ahuo *AgentHandoffUpdateOne) ClearFromTaskID() *AgentHandoffUpdateOne

ClearFromTaskID clears the value of the "from_task_id" field.

func (*AgentHandoffUpdateOne) ClearLatencyMs

func (ahuo *AgentHandoffUpdateOne) ClearLatencyMs() *AgentHandoffUpdateOne

ClearLatencyMs clears the value of the "latency_ms" field.

func (*AgentHandoffUpdateOne) ClearMetadata

func (ahuo *AgentHandoffUpdateOne) ClearMetadata() *AgentHandoffUpdateOne

ClearMetadata clears the value of the "metadata" field.

func (*AgentHandoffUpdateOne) ClearPayload

func (ahuo *AgentHandoffUpdateOne) ClearPayload() *AgentHandoffUpdateOne

ClearPayload clears the value of the "payload" field.

func (*AgentHandoffUpdateOne) ClearToAgentType

func (ahuo *AgentHandoffUpdateOne) ClearToAgentType() *AgentHandoffUpdateOne

ClearToAgentType clears the value of the "to_agent_type" field.

func (*AgentHandoffUpdateOne) ClearToTaskID

func (ahuo *AgentHandoffUpdateOne) ClearToTaskID() *AgentHandoffUpdateOne

ClearToTaskID clears the value of the "to_task_id" field.

func (*AgentHandoffUpdateOne) ClearTraceID

func (ahuo *AgentHandoffUpdateOne) ClearTraceID() *AgentHandoffUpdateOne

ClearTraceID clears the value of the "trace_id" field.

func (*AgentHandoffUpdateOne) ClearWorkflow

func (ahuo *AgentHandoffUpdateOne) ClearWorkflow() *AgentHandoffUpdateOne

ClearWorkflow clears the "workflow" edge to the Workflow entity.

func (*AgentHandoffUpdateOne) ClearWorkflowID

func (ahuo *AgentHandoffUpdateOne) ClearWorkflowID() *AgentHandoffUpdateOne

ClearWorkflowID clears the value of the "workflow_id" field.

func (*AgentHandoffUpdateOne) Exec

func (ahuo *AgentHandoffUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*AgentHandoffUpdateOne) ExecX

func (ahuo *AgentHandoffUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*AgentHandoffUpdateOne) Mutation

func (ahuo *AgentHandoffUpdateOne) Mutation() *AgentHandoffMutation

Mutation returns the AgentHandoffMutation object of the builder.

func (*AgentHandoffUpdateOne) Save

Save executes the query and returns the updated AgentHandoff entity.

func (*AgentHandoffUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*AgentHandoffUpdateOne) Select

func (ahuo *AgentHandoffUpdateOne) Select(field string, fields ...string) *AgentHandoffUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*AgentHandoffUpdateOne) SetAcceptedAt

func (ahuo *AgentHandoffUpdateOne) SetAcceptedAt(t time.Time) *AgentHandoffUpdateOne

SetAcceptedAt sets the "accepted_at" field.

func (*AgentHandoffUpdateOne) SetCompletedAt

func (ahuo *AgentHandoffUpdateOne) SetCompletedAt(t time.Time) *AgentHandoffUpdateOne

SetCompletedAt sets the "completed_at" field.

func (*AgentHandoffUpdateOne) SetErrorMessage

func (ahuo *AgentHandoffUpdateOne) SetErrorMessage(s string) *AgentHandoffUpdateOne

SetErrorMessage sets the "error_message" field.

func (*AgentHandoffUpdateOne) SetFromAgentID

func (ahuo *AgentHandoffUpdateOne) SetFromAgentID(s string) *AgentHandoffUpdateOne

SetFromAgentID sets the "from_agent_id" field.

func (*AgentHandoffUpdateOne) SetFromAgentType

func (ahuo *AgentHandoffUpdateOne) SetFromAgentType(s string) *AgentHandoffUpdateOne

SetFromAgentType sets the "from_agent_type" field.

func (*AgentHandoffUpdateOne) SetFromTaskID

func (ahuo *AgentHandoffUpdateOne) SetFromTaskID(s string) *AgentHandoffUpdateOne

SetFromTaskID sets the "from_task_id" field.

func (*AgentHandoffUpdateOne) SetHandoffType

func (ahuo *AgentHandoffUpdateOne) SetHandoffType(s string) *AgentHandoffUpdateOne

SetHandoffType sets the "handoff_type" field.

func (*AgentHandoffUpdateOne) SetLatencyMs

func (ahuo *AgentHandoffUpdateOne) SetLatencyMs(i int64) *AgentHandoffUpdateOne

SetLatencyMs sets the "latency_ms" field.

func (*AgentHandoffUpdateOne) SetMetadata

func (ahuo *AgentHandoffUpdateOne) SetMetadata(m map[string]interface{}) *AgentHandoffUpdateOne

SetMetadata sets the "metadata" field.

func (*AgentHandoffUpdateOne) SetNillableAcceptedAt

func (ahuo *AgentHandoffUpdateOne) SetNillableAcceptedAt(t *time.Time) *AgentHandoffUpdateOne

SetNillableAcceptedAt sets the "accepted_at" field if the given value is not nil.

func (*AgentHandoffUpdateOne) SetNillableCompletedAt

func (ahuo *AgentHandoffUpdateOne) SetNillableCompletedAt(t *time.Time) *AgentHandoffUpdateOne

SetNillableCompletedAt sets the "completed_at" field if the given value is not nil.

func (*AgentHandoffUpdateOne) SetNillableErrorMessage

func (ahuo *AgentHandoffUpdateOne) SetNillableErrorMessage(s *string) *AgentHandoffUpdateOne

SetNillableErrorMessage sets the "error_message" field if the given value is not nil.

func (*AgentHandoffUpdateOne) SetNillableFromAgentID

func (ahuo *AgentHandoffUpdateOne) SetNillableFromAgentID(s *string) *AgentHandoffUpdateOne

SetNillableFromAgentID sets the "from_agent_id" field if the given value is not nil.

func (*AgentHandoffUpdateOne) SetNillableFromAgentType

func (ahuo *AgentHandoffUpdateOne) SetNillableFromAgentType(s *string) *AgentHandoffUpdateOne

SetNillableFromAgentType sets the "from_agent_type" field if the given value is not nil.

func (*AgentHandoffUpdateOne) SetNillableFromTaskID

func (ahuo *AgentHandoffUpdateOne) SetNillableFromTaskID(s *string) *AgentHandoffUpdateOne

SetNillableFromTaskID sets the "from_task_id" field if the given value is not nil.

func (*AgentHandoffUpdateOne) SetNillableHandoffType

func (ahuo *AgentHandoffUpdateOne) SetNillableHandoffType(s *string) *AgentHandoffUpdateOne

SetNillableHandoffType sets the "handoff_type" field if the given value is not nil.

func (*AgentHandoffUpdateOne) SetNillableLatencyMs

func (ahuo *AgentHandoffUpdateOne) SetNillableLatencyMs(i *int64) *AgentHandoffUpdateOne

SetNillableLatencyMs sets the "latency_ms" field if the given value is not nil.

func (*AgentHandoffUpdateOne) SetNillablePayloadSizeBytes

func (ahuo *AgentHandoffUpdateOne) SetNillablePayloadSizeBytes(i *int) *AgentHandoffUpdateOne

SetNillablePayloadSizeBytes sets the "payload_size_bytes" field if the given value is not nil.

func (*AgentHandoffUpdateOne) SetNillableStatus

func (ahuo *AgentHandoffUpdateOne) SetNillableStatus(s *string) *AgentHandoffUpdateOne

SetNillableStatus sets the "status" field if the given value is not nil.

func (*AgentHandoffUpdateOne) SetNillableToAgentID

func (ahuo *AgentHandoffUpdateOne) SetNillableToAgentID(s *string) *AgentHandoffUpdateOne

SetNillableToAgentID sets the "to_agent_id" field if the given value is not nil.

func (*AgentHandoffUpdateOne) SetNillableToAgentType

func (ahuo *AgentHandoffUpdateOne) SetNillableToAgentType(s *string) *AgentHandoffUpdateOne

SetNillableToAgentType sets the "to_agent_type" field if the given value is not nil.

func (*AgentHandoffUpdateOne) SetNillableToTaskID

func (ahuo *AgentHandoffUpdateOne) SetNillableToTaskID(s *string) *AgentHandoffUpdateOne

SetNillableToTaskID sets the "to_task_id" field if the given value is not nil.

func (*AgentHandoffUpdateOne) SetNillableTraceID

func (ahuo *AgentHandoffUpdateOne) SetNillableTraceID(s *string) *AgentHandoffUpdateOne

SetNillableTraceID sets the "trace_id" field if the given value is not nil.

func (*AgentHandoffUpdateOne) SetNillableWorkflowID

func (ahuo *AgentHandoffUpdateOne) SetNillableWorkflowID(s *string) *AgentHandoffUpdateOne

SetNillableWorkflowID sets the "workflow_id" field if the given value is not nil.

func (*AgentHandoffUpdateOne) SetPayload

func (ahuo *AgentHandoffUpdateOne) SetPayload(m map[string]interface{}) *AgentHandoffUpdateOne

SetPayload sets the "payload" field.

func (*AgentHandoffUpdateOne) SetPayloadSizeBytes

func (ahuo *AgentHandoffUpdateOne) SetPayloadSizeBytes(i int) *AgentHandoffUpdateOne

SetPayloadSizeBytes sets the "payload_size_bytes" field.

func (*AgentHandoffUpdateOne) SetStatus

SetStatus sets the "status" field.

func (*AgentHandoffUpdateOne) SetToAgentID

func (ahuo *AgentHandoffUpdateOne) SetToAgentID(s string) *AgentHandoffUpdateOne

SetToAgentID sets the "to_agent_id" field.

func (*AgentHandoffUpdateOne) SetToAgentType

func (ahuo *AgentHandoffUpdateOne) SetToAgentType(s string) *AgentHandoffUpdateOne

SetToAgentType sets the "to_agent_type" field.

func (*AgentHandoffUpdateOne) SetToTaskID

func (ahuo *AgentHandoffUpdateOne) SetToTaskID(s string) *AgentHandoffUpdateOne

SetToTaskID sets the "to_task_id" field.

func (*AgentHandoffUpdateOne) SetTraceID

func (ahuo *AgentHandoffUpdateOne) SetTraceID(s string) *AgentHandoffUpdateOne

SetTraceID sets the "trace_id" field.

func (*AgentHandoffUpdateOne) SetUpdatedAt

func (ahuo *AgentHandoffUpdateOne) SetUpdatedAt(t time.Time) *AgentHandoffUpdateOne

SetUpdatedAt sets the "updated_at" field.

func (*AgentHandoffUpdateOne) SetWorkflow

func (ahuo *AgentHandoffUpdateOne) SetWorkflow(w *Workflow) *AgentHandoffUpdateOne

SetWorkflow sets the "workflow" edge to the Workflow entity.

func (*AgentHandoffUpdateOne) SetWorkflowID

func (ahuo *AgentHandoffUpdateOne) SetWorkflowID(s string) *AgentHandoffUpdateOne

SetWorkflowID sets the "workflow_id" field.

func (*AgentHandoffUpdateOne) Where

Where appends a list predicates to the AgentHandoffUpdate builder.

type AgentHandoffs

type AgentHandoffs []*AgentHandoff

AgentHandoffs is a parsable slice of AgentHandoff.

type AgentTask

type AgentTask struct {

	// ID of the ent.
	// Unique task identifier (UUID)
	ID string `json:"id,omitempty"`
	// Parent workflow ID
	WorkflowID string `json:"workflow_id,omitempty"`
	// Agent that executed this task
	AgentID string `json:"agent_id,omitempty"`
	// Type of agent (e.g., 'synthesis', 'verification', 'research')
	AgentType string `json:"agent_type,omitempty"`
	// Type of task (e.g., 'extract_statistics', 'verify_source')
	TaskType string `json:"task_type,omitempty"`
	// Human-readable task name
	Name string `json:"name,omitempty"`
	// Task status: pending, running, completed, failed, cancelled
	Status string `json:"status,omitempty"`
	// OpenTelemetry trace ID
	TraceID string `json:"trace_id,omitempty"`
	// OpenTelemetry span ID
	SpanID string `json:"span_id,omitempty"`
	// Parent span ID for nested tasks
	ParentSpanID string `json:"parent_span_id,omitempty"`
	// Task input data
	Input map[string]interface{} `json:"input,omitempty"`
	// Task output/result data
	Output map[string]interface{} `json:"output,omitempty"`
	// Additional metadata
	Metadata map[string]interface{} `json:"metadata,omitempty"`
	// Number of LLM calls made
	LlmCallCount int `json:"llm_call_count,omitempty"`
	// Number of tool invocations
	ToolCallCount int `json:"tool_call_count,omitempty"`
	// Number of retries attempted
	RetryCount int `json:"retry_count,omitempty"`
	// Prompt tokens used
	TokensPrompt int `json:"tokens_prompt,omitempty"`
	// Completion tokens used
	TokensCompletion int `json:"tokens_completion,omitempty"`
	// Total tokens used
	TokensTotal int `json:"tokens_total,omitempty"`
	// Cost in USD
	CostUsd float64 `json:"cost_usd,omitempty"`
	// Task duration in milliseconds
	DurationMs int64 `json:"duration_ms,omitempty"`
	// Error type if task failed
	ErrorType string `json:"error_type,omitempty"`
	// Error message if task failed
	ErrorMessage string `json:"error_message,omitempty"`
	// When the task started
	StartedAt time.Time `json:"started_at,omitempty"`
	// When the task ended
	EndedAt *time.Time `json:"ended_at,omitempty"`
	// CreatedAt holds the value of the "created_at" field.
	CreatedAt time.Time `json:"created_at,omitempty"`
	// UpdatedAt holds the value of the "updated_at" field.
	UpdatedAt time.Time `json:"updated_at,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the AgentTaskQuery when eager-loading is set.
	Edges AgentTaskEdges `json:"edges"`
	// contains filtered or unexported fields
}

AgentTask is the model entity for the AgentTask schema.

func (*AgentTask) QueryEvents

func (at *AgentTask) QueryEvents() *AgentEventQuery

QueryEvents queries the "events" edge of the AgentTask entity.

func (*AgentTask) QueryToolInvocations

func (at *AgentTask) QueryToolInvocations() *ToolInvocationQuery

QueryToolInvocations queries the "tool_invocations" edge of the AgentTask entity.

func (*AgentTask) QueryWorkflow

func (at *AgentTask) QueryWorkflow() *WorkflowQuery

QueryWorkflow queries the "workflow" edge of the AgentTask entity.

func (*AgentTask) String

func (at *AgentTask) String() string

String implements the fmt.Stringer.

func (*AgentTask) Unwrap

func (at *AgentTask) Unwrap() *AgentTask

Unwrap unwraps the AgentTask entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*AgentTask) Update

func (at *AgentTask) Update() *AgentTaskUpdateOne

Update returns a builder for updating this AgentTask. Note that you need to call AgentTask.Unwrap() before calling this method if this AgentTask was returned from a transaction, and the transaction was committed or rolled back.

func (*AgentTask) Value

func (at *AgentTask) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the AgentTask. This includes values selected through modifiers, order, etc.

type AgentTaskClient

type AgentTaskClient struct {
	// contains filtered or unexported fields
}

AgentTaskClient is a client for the AgentTask schema.

func NewAgentTaskClient

func NewAgentTaskClient(c config) *AgentTaskClient

NewAgentTaskClient returns a client for the AgentTask from the given config.

func (*AgentTaskClient) Create

func (c *AgentTaskClient) Create() *AgentTaskCreate

Create returns a builder for creating a AgentTask entity.

func (*AgentTaskClient) CreateBulk

func (c *AgentTaskClient) CreateBulk(builders ...*AgentTaskCreate) *AgentTaskCreateBulk

CreateBulk returns a builder for creating a bulk of AgentTask entities.

func (*AgentTaskClient) Delete

func (c *AgentTaskClient) Delete() *AgentTaskDelete

Delete returns a delete builder for AgentTask.

func (*AgentTaskClient) DeleteOne

func (c *AgentTaskClient) DeleteOne(at *AgentTask) *AgentTaskDeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*AgentTaskClient) DeleteOneID

func (c *AgentTaskClient) DeleteOneID(id string) *AgentTaskDeleteOne

DeleteOneID returns a builder for deleting the given entity by its id.

func (*AgentTaskClient) Get

func (c *AgentTaskClient) Get(ctx context.Context, id string) (*AgentTask, error)

Get returns a AgentTask entity by its id.

func (*AgentTaskClient) GetX

func (c *AgentTaskClient) GetX(ctx context.Context, id string) *AgentTask

GetX is like Get, but panics if an error occurs.

func (*AgentTaskClient) Hooks

func (c *AgentTaskClient) Hooks() []Hook

Hooks returns the client hooks.

func (*AgentTaskClient) Intercept

func (c *AgentTaskClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `agenttask.Intercept(f(g(h())))`.

func (*AgentTaskClient) Interceptors

func (c *AgentTaskClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*AgentTaskClient) MapCreateBulk

func (c *AgentTaskClient) MapCreateBulk(slice any, setFunc func(*AgentTaskCreate, int)) *AgentTaskCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*AgentTaskClient) Query

func (c *AgentTaskClient) Query() *AgentTaskQuery

Query returns a query builder for AgentTask.

func (*AgentTaskClient) QueryEvents

func (c *AgentTaskClient) QueryEvents(at *AgentTask) *AgentEventQuery

QueryEvents queries the events edge of a AgentTask.

func (*AgentTaskClient) QueryToolInvocations

func (c *AgentTaskClient) QueryToolInvocations(at *AgentTask) *ToolInvocationQuery

QueryToolInvocations queries the tool_invocations edge of a AgentTask.

func (*AgentTaskClient) QueryWorkflow

func (c *AgentTaskClient) QueryWorkflow(at *AgentTask) *WorkflowQuery

QueryWorkflow queries the workflow edge of a AgentTask.

func (*AgentTaskClient) Update

func (c *AgentTaskClient) Update() *AgentTaskUpdate

Update returns an update builder for AgentTask.

func (*AgentTaskClient) UpdateOne

func (c *AgentTaskClient) UpdateOne(at *AgentTask) *AgentTaskUpdateOne

UpdateOne returns an update builder for the given entity.

func (*AgentTaskClient) UpdateOneID

func (c *AgentTaskClient) UpdateOneID(id string) *AgentTaskUpdateOne

UpdateOneID returns an update builder for the given id.

func (*AgentTaskClient) Use

func (c *AgentTaskClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `agenttask.Hooks(f(g(h())))`.

type AgentTaskCreate

type AgentTaskCreate struct {
	// contains filtered or unexported fields
}

AgentTaskCreate is the builder for creating a AgentTask entity.

func (*AgentTaskCreate) AddEventIDs

func (atc *AgentTaskCreate) AddEventIDs(ids ...string) *AgentTaskCreate

AddEventIDs adds the "events" edge to the AgentEvent entity by IDs.

func (*AgentTaskCreate) AddEvents

func (atc *AgentTaskCreate) AddEvents(a ...*AgentEvent) *AgentTaskCreate

AddEvents adds the "events" edges to the AgentEvent entity.

func (*AgentTaskCreate) AddToolInvocationIDs

func (atc *AgentTaskCreate) AddToolInvocationIDs(ids ...string) *AgentTaskCreate

AddToolInvocationIDs adds the "tool_invocations" edge to the ToolInvocation entity by IDs.

func (*AgentTaskCreate) AddToolInvocations

func (atc *AgentTaskCreate) AddToolInvocations(t ...*ToolInvocation) *AgentTaskCreate

AddToolInvocations adds the "tool_invocations" edges to the ToolInvocation entity.

func (*AgentTaskCreate) Exec

func (atc *AgentTaskCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*AgentTaskCreate) ExecX

func (atc *AgentTaskCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*AgentTaskCreate) Mutation

func (atc *AgentTaskCreate) Mutation() *AgentTaskMutation

Mutation returns the AgentTaskMutation object of the builder.

func (*AgentTaskCreate) Save

func (atc *AgentTaskCreate) Save(ctx context.Context) (*AgentTask, error)

Save creates the AgentTask in the database.

func (*AgentTaskCreate) SaveX

func (atc *AgentTaskCreate) SaveX(ctx context.Context) *AgentTask

SaveX calls Save and panics if Save returns an error.

func (*AgentTaskCreate) SetAgentID

func (atc *AgentTaskCreate) SetAgentID(s string) *AgentTaskCreate

SetAgentID sets the "agent_id" field.

func (*AgentTaskCreate) SetAgentType

func (atc *AgentTaskCreate) SetAgentType(s string) *AgentTaskCreate

SetAgentType sets the "agent_type" field.

func (*AgentTaskCreate) SetCostUsd

func (atc *AgentTaskCreate) SetCostUsd(f float64) *AgentTaskCreate

SetCostUsd sets the "cost_usd" field.

func (*AgentTaskCreate) SetCreatedAt

func (atc *AgentTaskCreate) SetCreatedAt(t time.Time) *AgentTaskCreate

SetCreatedAt sets the "created_at" field.

func (*AgentTaskCreate) SetDurationMs

func (atc *AgentTaskCreate) SetDurationMs(i int64) *AgentTaskCreate

SetDurationMs sets the "duration_ms" field.

func (*AgentTaskCreate) SetEndedAt

func (atc *AgentTaskCreate) SetEndedAt(t time.Time) *AgentTaskCreate

SetEndedAt sets the "ended_at" field.

func (*AgentTaskCreate) SetErrorMessage

func (atc *AgentTaskCreate) SetErrorMessage(s string) *AgentTaskCreate

SetErrorMessage sets the "error_message" field.

func (*AgentTaskCreate) SetErrorType

func (atc *AgentTaskCreate) SetErrorType(s string) *AgentTaskCreate

SetErrorType sets the "error_type" field.

func (*AgentTaskCreate) SetID

func (atc *AgentTaskCreate) SetID(s string) *AgentTaskCreate

SetID sets the "id" field.

func (*AgentTaskCreate) SetInput

func (atc *AgentTaskCreate) SetInput(m map[string]interface{}) *AgentTaskCreate

SetInput sets the "input" field.

func (*AgentTaskCreate) SetLlmCallCount

func (atc *AgentTaskCreate) SetLlmCallCount(i int) *AgentTaskCreate

SetLlmCallCount sets the "llm_call_count" field.

func (*AgentTaskCreate) SetMetadata

func (atc *AgentTaskCreate) SetMetadata(m map[string]interface{}) *AgentTaskCreate

SetMetadata sets the "metadata" field.

func (*AgentTaskCreate) SetName

func (atc *AgentTaskCreate) SetName(s string) *AgentTaskCreate

SetName sets the "name" field.

func (*AgentTaskCreate) SetNillableAgentType

func (atc *AgentTaskCreate) SetNillableAgentType(s *string) *AgentTaskCreate

SetNillableAgentType sets the "agent_type" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableCostUsd

func (atc *AgentTaskCreate) SetNillableCostUsd(f *float64) *AgentTaskCreate

SetNillableCostUsd sets the "cost_usd" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableCreatedAt

func (atc *AgentTaskCreate) SetNillableCreatedAt(t *time.Time) *AgentTaskCreate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableDurationMs

func (atc *AgentTaskCreate) SetNillableDurationMs(i *int64) *AgentTaskCreate

SetNillableDurationMs sets the "duration_ms" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableEndedAt

func (atc *AgentTaskCreate) SetNillableEndedAt(t *time.Time) *AgentTaskCreate

SetNillableEndedAt sets the "ended_at" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableErrorMessage

func (atc *AgentTaskCreate) SetNillableErrorMessage(s *string) *AgentTaskCreate

SetNillableErrorMessage sets the "error_message" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableErrorType

func (atc *AgentTaskCreate) SetNillableErrorType(s *string) *AgentTaskCreate

SetNillableErrorType sets the "error_type" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableLlmCallCount

func (atc *AgentTaskCreate) SetNillableLlmCallCount(i *int) *AgentTaskCreate

SetNillableLlmCallCount sets the "llm_call_count" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableParentSpanID

func (atc *AgentTaskCreate) SetNillableParentSpanID(s *string) *AgentTaskCreate

SetNillableParentSpanID sets the "parent_span_id" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableRetryCount

func (atc *AgentTaskCreate) SetNillableRetryCount(i *int) *AgentTaskCreate

SetNillableRetryCount sets the "retry_count" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableSpanID

func (atc *AgentTaskCreate) SetNillableSpanID(s *string) *AgentTaskCreate

SetNillableSpanID sets the "span_id" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableStartedAt

func (atc *AgentTaskCreate) SetNillableStartedAt(t *time.Time) *AgentTaskCreate

SetNillableStartedAt sets the "started_at" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableStatus

func (atc *AgentTaskCreate) SetNillableStatus(s *string) *AgentTaskCreate

SetNillableStatus sets the "status" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableTokensCompletion

func (atc *AgentTaskCreate) SetNillableTokensCompletion(i *int) *AgentTaskCreate

SetNillableTokensCompletion sets the "tokens_completion" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableTokensPrompt

func (atc *AgentTaskCreate) SetNillableTokensPrompt(i *int) *AgentTaskCreate

SetNillableTokensPrompt sets the "tokens_prompt" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableTokensTotal

func (atc *AgentTaskCreate) SetNillableTokensTotal(i *int) *AgentTaskCreate

SetNillableTokensTotal sets the "tokens_total" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableToolCallCount

func (atc *AgentTaskCreate) SetNillableToolCallCount(i *int) *AgentTaskCreate

SetNillableToolCallCount sets the "tool_call_count" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableTraceID

func (atc *AgentTaskCreate) SetNillableTraceID(s *string) *AgentTaskCreate

SetNillableTraceID sets the "trace_id" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableUpdatedAt

func (atc *AgentTaskCreate) SetNillableUpdatedAt(t *time.Time) *AgentTaskCreate

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*AgentTaskCreate) SetNillableWorkflowID

func (atc *AgentTaskCreate) SetNillableWorkflowID(s *string) *AgentTaskCreate

SetNillableWorkflowID sets the "workflow_id" field if the given value is not nil.

func (*AgentTaskCreate) SetOutput

func (atc *AgentTaskCreate) SetOutput(m map[string]interface{}) *AgentTaskCreate

SetOutput sets the "output" field.

func (*AgentTaskCreate) SetParentSpanID

func (atc *AgentTaskCreate) SetParentSpanID(s string) *AgentTaskCreate

SetParentSpanID sets the "parent_span_id" field.

func (*AgentTaskCreate) SetRetryCount

func (atc *AgentTaskCreate) SetRetryCount(i int) *AgentTaskCreate

SetRetryCount sets the "retry_count" field.

func (*AgentTaskCreate) SetSpanID

func (atc *AgentTaskCreate) SetSpanID(s string) *AgentTaskCreate

SetSpanID sets the "span_id" field.

func (*AgentTaskCreate) SetStartedAt

func (atc *AgentTaskCreate) SetStartedAt(t time.Time) *AgentTaskCreate

SetStartedAt sets the "started_at" field.

func (*AgentTaskCreate) SetStatus

func (atc *AgentTaskCreate) SetStatus(s string) *AgentTaskCreate

SetStatus sets the "status" field.

func (*AgentTaskCreate) SetTaskType

func (atc *AgentTaskCreate) SetTaskType(s string) *AgentTaskCreate

SetTaskType sets the "task_type" field.

func (*AgentTaskCreate) SetTokensCompletion

func (atc *AgentTaskCreate) SetTokensCompletion(i int) *AgentTaskCreate

SetTokensCompletion sets the "tokens_completion" field.

func (*AgentTaskCreate) SetTokensPrompt

func (atc *AgentTaskCreate) SetTokensPrompt(i int) *AgentTaskCreate

SetTokensPrompt sets the "tokens_prompt" field.

func (*AgentTaskCreate) SetTokensTotal

func (atc *AgentTaskCreate) SetTokensTotal(i int) *AgentTaskCreate

SetTokensTotal sets the "tokens_total" field.

func (*AgentTaskCreate) SetToolCallCount

func (atc *AgentTaskCreate) SetToolCallCount(i int) *AgentTaskCreate

SetToolCallCount sets the "tool_call_count" field.

func (*AgentTaskCreate) SetTraceID

func (atc *AgentTaskCreate) SetTraceID(s string) *AgentTaskCreate

SetTraceID sets the "trace_id" field.

func (*AgentTaskCreate) SetUpdatedAt

func (atc *AgentTaskCreate) SetUpdatedAt(t time.Time) *AgentTaskCreate

SetUpdatedAt sets the "updated_at" field.

func (*AgentTaskCreate) SetWorkflow

func (atc *AgentTaskCreate) SetWorkflow(w *Workflow) *AgentTaskCreate

SetWorkflow sets the "workflow" edge to the Workflow entity.

func (*AgentTaskCreate) SetWorkflowID

func (atc *AgentTaskCreate) SetWorkflowID(s string) *AgentTaskCreate

SetWorkflowID sets the "workflow_id" field.

type AgentTaskCreateBulk

type AgentTaskCreateBulk struct {
	// contains filtered or unexported fields
}

AgentTaskCreateBulk is the builder for creating many AgentTask entities in bulk.

func (*AgentTaskCreateBulk) Exec

func (atcb *AgentTaskCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*AgentTaskCreateBulk) ExecX

func (atcb *AgentTaskCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*AgentTaskCreateBulk) Save

func (atcb *AgentTaskCreateBulk) Save(ctx context.Context) ([]*AgentTask, error)

Save creates the AgentTask entities in the database.

func (*AgentTaskCreateBulk) SaveX

func (atcb *AgentTaskCreateBulk) SaveX(ctx context.Context) []*AgentTask

SaveX is like Save, but panics if an error occurs.

type AgentTaskDelete

type AgentTaskDelete struct {
	// contains filtered or unexported fields
}

AgentTaskDelete is the builder for deleting a AgentTask entity.

func (*AgentTaskDelete) Exec

func (atd *AgentTaskDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*AgentTaskDelete) ExecX

func (atd *AgentTaskDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*AgentTaskDelete) Where

Where appends a list predicates to the AgentTaskDelete builder.

type AgentTaskDeleteOne

type AgentTaskDeleteOne struct {
	// contains filtered or unexported fields
}

AgentTaskDeleteOne is the builder for deleting a single AgentTask entity.

func (*AgentTaskDeleteOne) Exec

func (atdo *AgentTaskDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*AgentTaskDeleteOne) ExecX

func (atdo *AgentTaskDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*AgentTaskDeleteOne) Where

Where appends a list predicates to the AgentTaskDelete builder.

type AgentTaskEdges

type AgentTaskEdges struct {
	// Workflow holds the value of the workflow edge.
	Workflow *Workflow `json:"workflow,omitempty"`
	// Tool invocations made during this task
	ToolInvocations []*ToolInvocation `json:"tool_invocations,omitempty"`
	// Events during this task
	Events []*AgentEvent `json:"events,omitempty"`
	// contains filtered or unexported fields
}

AgentTaskEdges holds the relations/edges for other nodes in the graph.

func (AgentTaskEdges) EventsOrErr

func (e AgentTaskEdges) EventsOrErr() ([]*AgentEvent, error)

EventsOrErr returns the Events value or an error if the edge was not loaded in eager-loading.

func (AgentTaskEdges) ToolInvocationsOrErr

func (e AgentTaskEdges) ToolInvocationsOrErr() ([]*ToolInvocation, error)

ToolInvocationsOrErr returns the ToolInvocations value or an error if the edge was not loaded in eager-loading.

func (AgentTaskEdges) WorkflowOrErr

func (e AgentTaskEdges) WorkflowOrErr() (*Workflow, error)

WorkflowOrErr returns the Workflow value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

type AgentTaskGroupBy

type AgentTaskGroupBy struct {
	// contains filtered or unexported fields
}

AgentTaskGroupBy is the group-by builder for AgentTask entities.

func (*AgentTaskGroupBy) Aggregate

func (atgb *AgentTaskGroupBy) Aggregate(fns ...AggregateFunc) *AgentTaskGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*AgentTaskGroupBy) Bool

func (s *AgentTaskGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*AgentTaskGroupBy) BoolX

func (s *AgentTaskGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*AgentTaskGroupBy) Bools

func (s *AgentTaskGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*AgentTaskGroupBy) BoolsX

func (s *AgentTaskGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*AgentTaskGroupBy) Float64

func (s *AgentTaskGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*AgentTaskGroupBy) Float64X

func (s *AgentTaskGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*AgentTaskGroupBy) Float64s

func (s *AgentTaskGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*AgentTaskGroupBy) Float64sX

func (s *AgentTaskGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*AgentTaskGroupBy) Int

func (s *AgentTaskGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*AgentTaskGroupBy) IntX

func (s *AgentTaskGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*AgentTaskGroupBy) Ints

func (s *AgentTaskGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*AgentTaskGroupBy) IntsX

func (s *AgentTaskGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*AgentTaskGroupBy) Scan

func (atgb *AgentTaskGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*AgentTaskGroupBy) ScanX

func (s *AgentTaskGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*AgentTaskGroupBy) String

func (s *AgentTaskGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*AgentTaskGroupBy) StringX

func (s *AgentTaskGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*AgentTaskGroupBy) Strings

func (s *AgentTaskGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*AgentTaskGroupBy) StringsX

func (s *AgentTaskGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type AgentTaskMutation

type AgentTaskMutation struct {
	// contains filtered or unexported fields
}

AgentTaskMutation represents an operation that mutates the AgentTask nodes in the graph.

func (*AgentTaskMutation) AddCostUsd

func (m *AgentTaskMutation) AddCostUsd(f float64)

AddCostUsd adds f to the "cost_usd" field.

func (*AgentTaskMutation) AddDurationMs

func (m *AgentTaskMutation) AddDurationMs(i int64)

AddDurationMs adds i to the "duration_ms" field.

func (*AgentTaskMutation) AddEventIDs

func (m *AgentTaskMutation) AddEventIDs(ids ...string)

AddEventIDs adds the "events" edge to the AgentEvent entity by ids.

func (*AgentTaskMutation) AddField

func (m *AgentTaskMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*AgentTaskMutation) AddLlmCallCount

func (m *AgentTaskMutation) AddLlmCallCount(i int)

AddLlmCallCount adds i to the "llm_call_count" field.

func (*AgentTaskMutation) AddRetryCount

func (m *AgentTaskMutation) AddRetryCount(i int)

AddRetryCount adds i to the "retry_count" field.

func (*AgentTaskMutation) AddTokensCompletion

func (m *AgentTaskMutation) AddTokensCompletion(i int)

AddTokensCompletion adds i to the "tokens_completion" field.

func (*AgentTaskMutation) AddTokensPrompt

func (m *AgentTaskMutation) AddTokensPrompt(i int)

AddTokensPrompt adds i to the "tokens_prompt" field.

func (*AgentTaskMutation) AddTokensTotal

func (m *AgentTaskMutation) AddTokensTotal(i int)

AddTokensTotal adds i to the "tokens_total" field.

func (*AgentTaskMutation) AddToolCallCount

func (m *AgentTaskMutation) AddToolCallCount(i int)

AddToolCallCount adds i to the "tool_call_count" field.

func (*AgentTaskMutation) AddToolInvocationIDs

func (m *AgentTaskMutation) AddToolInvocationIDs(ids ...string)

AddToolInvocationIDs adds the "tool_invocations" edge to the ToolInvocation entity by ids.

func (*AgentTaskMutation) AddedCostUsd

func (m *AgentTaskMutation) AddedCostUsd() (r float64, exists bool)

AddedCostUsd returns the value that was added to the "cost_usd" field in this mutation.

func (*AgentTaskMutation) AddedDurationMs

func (m *AgentTaskMutation) AddedDurationMs() (r int64, exists bool)

AddedDurationMs returns the value that was added to the "duration_ms" field in this mutation.

func (*AgentTaskMutation) AddedEdges

func (m *AgentTaskMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*AgentTaskMutation) AddedField

func (m *AgentTaskMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*AgentTaskMutation) AddedFields

func (m *AgentTaskMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*AgentTaskMutation) AddedIDs

func (m *AgentTaskMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*AgentTaskMutation) AddedLlmCallCount

func (m *AgentTaskMutation) AddedLlmCallCount() (r int, exists bool)

AddedLlmCallCount returns the value that was added to the "llm_call_count" field in this mutation.

func (*AgentTaskMutation) AddedRetryCount

func (m *AgentTaskMutation) AddedRetryCount() (r int, exists bool)

AddedRetryCount returns the value that was added to the "retry_count" field in this mutation.

func (*AgentTaskMutation) AddedTokensCompletion

func (m *AgentTaskMutation) AddedTokensCompletion() (r int, exists bool)

AddedTokensCompletion returns the value that was added to the "tokens_completion" field in this mutation.

func (*AgentTaskMutation) AddedTokensPrompt

func (m *AgentTaskMutation) AddedTokensPrompt() (r int, exists bool)

AddedTokensPrompt returns the value that was added to the "tokens_prompt" field in this mutation.

func (*AgentTaskMutation) AddedTokensTotal

func (m *AgentTaskMutation) AddedTokensTotal() (r int, exists bool)

AddedTokensTotal returns the value that was added to the "tokens_total" field in this mutation.

func (*AgentTaskMutation) AddedToolCallCount

func (m *AgentTaskMutation) AddedToolCallCount() (r int, exists bool)

AddedToolCallCount returns the value that was added to the "tool_call_count" field in this mutation.

func (*AgentTaskMutation) AgentID

func (m *AgentTaskMutation) AgentID() (r string, exists bool)

AgentID returns the value of the "agent_id" field in the mutation.

func (*AgentTaskMutation) AgentType

func (m *AgentTaskMutation) AgentType() (r string, exists bool)

AgentType returns the value of the "agent_type" field in the mutation.

func (*AgentTaskMutation) AgentTypeCleared

func (m *AgentTaskMutation) AgentTypeCleared() bool

AgentTypeCleared returns if the "agent_type" field was cleared in this mutation.

func (*AgentTaskMutation) ClearAgentType

func (m *AgentTaskMutation) ClearAgentType()

ClearAgentType clears the value of the "agent_type" field.

func (*AgentTaskMutation) ClearDurationMs

func (m *AgentTaskMutation) ClearDurationMs()

ClearDurationMs clears the value of the "duration_ms" field.

func (*AgentTaskMutation) ClearEdge

func (m *AgentTaskMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*AgentTaskMutation) ClearEndedAt

func (m *AgentTaskMutation) ClearEndedAt()

ClearEndedAt clears the value of the "ended_at" field.

func (*AgentTaskMutation) ClearErrorMessage

func (m *AgentTaskMutation) ClearErrorMessage()

ClearErrorMessage clears the value of the "error_message" field.

func (*AgentTaskMutation) ClearErrorType

func (m *AgentTaskMutation) ClearErrorType()

ClearErrorType clears the value of the "error_type" field.

func (*AgentTaskMutation) ClearEvents

func (m *AgentTaskMutation) ClearEvents()

ClearEvents clears the "events" edge to the AgentEvent entity.

func (*AgentTaskMutation) ClearField

func (m *AgentTaskMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*AgentTaskMutation) ClearInput

func (m *AgentTaskMutation) ClearInput()

ClearInput clears the value of the "input" field.

func (*AgentTaskMutation) ClearMetadata

func (m *AgentTaskMutation) ClearMetadata()

ClearMetadata clears the value of the "metadata" field.

func (*AgentTaskMutation) ClearOutput

func (m *AgentTaskMutation) ClearOutput()

ClearOutput clears the value of the "output" field.

func (*AgentTaskMutation) ClearParentSpanID

func (m *AgentTaskMutation) ClearParentSpanID()

ClearParentSpanID clears the value of the "parent_span_id" field.

func (*AgentTaskMutation) ClearSpanID

func (m *AgentTaskMutation) ClearSpanID()

ClearSpanID clears the value of the "span_id" field.

func (*AgentTaskMutation) ClearToolInvocations

func (m *AgentTaskMutation) ClearToolInvocations()

ClearToolInvocations clears the "tool_invocations" edge to the ToolInvocation entity.

func (*AgentTaskMutation) ClearTraceID

func (m *AgentTaskMutation) ClearTraceID()

ClearTraceID clears the value of the "trace_id" field.

func (*AgentTaskMutation) ClearWorkflow

func (m *AgentTaskMutation) ClearWorkflow()

ClearWorkflow clears the "workflow" edge to the Workflow entity.

func (*AgentTaskMutation) ClearWorkflowID

func (m *AgentTaskMutation) ClearWorkflowID()

ClearWorkflowID clears the value of the "workflow_id" field.

func (*AgentTaskMutation) ClearedEdges

func (m *AgentTaskMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*AgentTaskMutation) ClearedFields

func (m *AgentTaskMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (AgentTaskMutation) Client

func (m AgentTaskMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*AgentTaskMutation) CostUsd

func (m *AgentTaskMutation) CostUsd() (r float64, exists bool)

CostUsd returns the value of the "cost_usd" field in the mutation.

func (*AgentTaskMutation) CreatedAt

func (m *AgentTaskMutation) CreatedAt() (r time.Time, exists bool)

CreatedAt returns the value of the "created_at" field in the mutation.

func (*AgentTaskMutation) DurationMs

func (m *AgentTaskMutation) DurationMs() (r int64, exists bool)

DurationMs returns the value of the "duration_ms" field in the mutation.

func (*AgentTaskMutation) DurationMsCleared

func (m *AgentTaskMutation) DurationMsCleared() bool

DurationMsCleared returns if the "duration_ms" field was cleared in this mutation.

func (*AgentTaskMutation) EdgeCleared

func (m *AgentTaskMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*AgentTaskMutation) EndedAt

func (m *AgentTaskMutation) EndedAt() (r time.Time, exists bool)

EndedAt returns the value of the "ended_at" field in the mutation.

func (*AgentTaskMutation) EndedAtCleared

func (m *AgentTaskMutation) EndedAtCleared() bool

EndedAtCleared returns if the "ended_at" field was cleared in this mutation.

func (*AgentTaskMutation) ErrorMessage

func (m *AgentTaskMutation) ErrorMessage() (r string, exists bool)

ErrorMessage returns the value of the "error_message" field in the mutation.

func (*AgentTaskMutation) ErrorMessageCleared

func (m *AgentTaskMutation) ErrorMessageCleared() bool

ErrorMessageCleared returns if the "error_message" field was cleared in this mutation.

func (*AgentTaskMutation) ErrorType

func (m *AgentTaskMutation) ErrorType() (r string, exists bool)

ErrorType returns the value of the "error_type" field in the mutation.

func (*AgentTaskMutation) ErrorTypeCleared

func (m *AgentTaskMutation) ErrorTypeCleared() bool

ErrorTypeCleared returns if the "error_type" field was cleared in this mutation.

func (*AgentTaskMutation) EventsCleared

func (m *AgentTaskMutation) EventsCleared() bool

EventsCleared reports if the "events" edge to the AgentEvent entity was cleared.

func (*AgentTaskMutation) EventsIDs

func (m *AgentTaskMutation) EventsIDs() (ids []string)

EventsIDs returns the "events" edge IDs in the mutation.

func (*AgentTaskMutation) Field

func (m *AgentTaskMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*AgentTaskMutation) FieldCleared

func (m *AgentTaskMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*AgentTaskMutation) Fields

func (m *AgentTaskMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*AgentTaskMutation) ID

func (m *AgentTaskMutation) ID() (id string, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*AgentTaskMutation) IDs

func (m *AgentTaskMutation) IDs(ctx context.Context) ([]string, error)

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*AgentTaskMutation) Input

func (m *AgentTaskMutation) Input() (r map[string]interface{}, exists bool)

Input returns the value of the "input" field in the mutation.

func (*AgentTaskMutation) InputCleared

func (m *AgentTaskMutation) InputCleared() bool

InputCleared returns if the "input" field was cleared in this mutation.

func (*AgentTaskMutation) LlmCallCount

func (m *AgentTaskMutation) LlmCallCount() (r int, exists bool)

LlmCallCount returns the value of the "llm_call_count" field in the mutation.

func (*AgentTaskMutation) Metadata

func (m *AgentTaskMutation) Metadata() (r map[string]interface{}, exists bool)

Metadata returns the value of the "metadata" field in the mutation.

func (*AgentTaskMutation) MetadataCleared

func (m *AgentTaskMutation) MetadataCleared() bool

MetadataCleared returns if the "metadata" field was cleared in this mutation.

func (*AgentTaskMutation) Name

func (m *AgentTaskMutation) Name() (r string, exists bool)

Name returns the value of the "name" field in the mutation.

func (*AgentTaskMutation) OldAgentID

func (m *AgentTaskMutation) OldAgentID(ctx context.Context) (v string, err error)

OldAgentID returns the old "agent_id" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldAgentType

func (m *AgentTaskMutation) OldAgentType(ctx context.Context) (v string, err error)

OldAgentType returns the old "agent_type" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldCostUsd

func (m *AgentTaskMutation) OldCostUsd(ctx context.Context) (v float64, err error)

OldCostUsd returns the old "cost_usd" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldCreatedAt

func (m *AgentTaskMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)

OldCreatedAt returns the old "created_at" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldDurationMs

func (m *AgentTaskMutation) OldDurationMs(ctx context.Context) (v int64, err error)

OldDurationMs returns the old "duration_ms" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldEndedAt

func (m *AgentTaskMutation) OldEndedAt(ctx context.Context) (v *time.Time, err error)

OldEndedAt returns the old "ended_at" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldErrorMessage

func (m *AgentTaskMutation) OldErrorMessage(ctx context.Context) (v string, err error)

OldErrorMessage returns the old "error_message" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldErrorType

func (m *AgentTaskMutation) OldErrorType(ctx context.Context) (v string, err error)

OldErrorType returns the old "error_type" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldField

func (m *AgentTaskMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*AgentTaskMutation) OldInput

func (m *AgentTaskMutation) OldInput(ctx context.Context) (v map[string]interface{}, err error)

OldInput returns the old "input" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldLlmCallCount

func (m *AgentTaskMutation) OldLlmCallCount(ctx context.Context) (v int, err error)

OldLlmCallCount returns the old "llm_call_count" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldMetadata

func (m *AgentTaskMutation) OldMetadata(ctx context.Context) (v map[string]interface{}, err error)

OldMetadata returns the old "metadata" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldName

func (m *AgentTaskMutation) OldName(ctx context.Context) (v string, err error)

OldName returns the old "name" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldOutput

func (m *AgentTaskMutation) OldOutput(ctx context.Context) (v map[string]interface{}, err error)

OldOutput returns the old "output" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldParentSpanID

func (m *AgentTaskMutation) OldParentSpanID(ctx context.Context) (v string, err error)

OldParentSpanID returns the old "parent_span_id" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldRetryCount

func (m *AgentTaskMutation) OldRetryCount(ctx context.Context) (v int, err error)

OldRetryCount returns the old "retry_count" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldSpanID

func (m *AgentTaskMutation) OldSpanID(ctx context.Context) (v string, err error)

OldSpanID returns the old "span_id" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldStartedAt

func (m *AgentTaskMutation) OldStartedAt(ctx context.Context) (v time.Time, err error)

OldStartedAt returns the old "started_at" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldStatus

func (m *AgentTaskMutation) OldStatus(ctx context.Context) (v string, err error)

OldStatus returns the old "status" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldTaskType

func (m *AgentTaskMutation) OldTaskType(ctx context.Context) (v string, err error)

OldTaskType returns the old "task_type" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldTokensCompletion

func (m *AgentTaskMutation) OldTokensCompletion(ctx context.Context) (v int, err error)

OldTokensCompletion returns the old "tokens_completion" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldTokensPrompt

func (m *AgentTaskMutation) OldTokensPrompt(ctx context.Context) (v int, err error)

OldTokensPrompt returns the old "tokens_prompt" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldTokensTotal

func (m *AgentTaskMutation) OldTokensTotal(ctx context.Context) (v int, err error)

OldTokensTotal returns the old "tokens_total" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldToolCallCount

func (m *AgentTaskMutation) OldToolCallCount(ctx context.Context) (v int, err error)

OldToolCallCount returns the old "tool_call_count" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldTraceID

func (m *AgentTaskMutation) OldTraceID(ctx context.Context) (v string, err error)

OldTraceID returns the old "trace_id" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldUpdatedAt

func (m *AgentTaskMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)

OldUpdatedAt returns the old "updated_at" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) OldWorkflowID

func (m *AgentTaskMutation) OldWorkflowID(ctx context.Context) (v string, err error)

OldWorkflowID returns the old "workflow_id" field's value of the AgentTask entity. If the AgentTask object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*AgentTaskMutation) Op

func (m *AgentTaskMutation) Op() Op

Op returns the operation name.

func (*AgentTaskMutation) Output

func (m *AgentTaskMutation) Output() (r map[string]interface{}, exists bool)

Output returns the value of the "output" field in the mutation.

func (*AgentTaskMutation) OutputCleared

func (m *AgentTaskMutation) OutputCleared() bool

OutputCleared returns if the "output" field was cleared in this mutation.

func (*AgentTaskMutation) ParentSpanID

func (m *AgentTaskMutation) ParentSpanID() (r string, exists bool)

ParentSpanID returns the value of the "parent_span_id" field in the mutation.

func (*AgentTaskMutation) ParentSpanIDCleared

func (m *AgentTaskMutation) ParentSpanIDCleared() bool

ParentSpanIDCleared returns if the "parent_span_id" field was cleared in this mutation.

func (*AgentTaskMutation) RemoveEventIDs

func (m *AgentTaskMutation) RemoveEventIDs(ids ...string)

RemoveEventIDs removes the "events" edge to the AgentEvent entity by IDs.

func (*AgentTaskMutation) RemoveToolInvocationIDs

func (m *AgentTaskMutation) RemoveToolInvocationIDs(ids ...string)

RemoveToolInvocationIDs removes the "tool_invocations" edge to the ToolInvocation entity by IDs.

func (*AgentTaskMutation) RemovedEdges

func (m *AgentTaskMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*AgentTaskMutation) RemovedEventsIDs

func (m *AgentTaskMutation) RemovedEventsIDs() (ids []string)

RemovedEvents returns the removed IDs of the "events" edge to the AgentEvent entity.

func (*AgentTaskMutation) RemovedIDs

func (m *AgentTaskMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*AgentTaskMutation) RemovedToolInvocationsIDs

func (m *AgentTaskMutation) RemovedToolInvocationsIDs() (ids []string)

RemovedToolInvocations returns the removed IDs of the "tool_invocations" edge to the ToolInvocation entity.

func (*AgentTaskMutation) ResetAgentID

func (m *AgentTaskMutation) ResetAgentID()

ResetAgentID resets all changes to the "agent_id" field.

func (*AgentTaskMutation) ResetAgentType

func (m *AgentTaskMutation) ResetAgentType()

ResetAgentType resets all changes to the "agent_type" field.

func (*AgentTaskMutation) ResetCostUsd

func (m *AgentTaskMutation) ResetCostUsd()

ResetCostUsd resets all changes to the "cost_usd" field.

func (*AgentTaskMutation) ResetCreatedAt

func (m *AgentTaskMutation) ResetCreatedAt()

ResetCreatedAt resets all changes to the "created_at" field.

func (*AgentTaskMutation) ResetDurationMs

func (m *AgentTaskMutation) ResetDurationMs()

ResetDurationMs resets all changes to the "duration_ms" field.

func (*AgentTaskMutation) ResetEdge

func (m *AgentTaskMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*AgentTaskMutation) ResetEndedAt

func (m *AgentTaskMutation) ResetEndedAt()

ResetEndedAt resets all changes to the "ended_at" field.

func (*AgentTaskMutation) ResetErrorMessage

func (m *AgentTaskMutation) ResetErrorMessage()

ResetErrorMessage resets all changes to the "error_message" field.

func (*AgentTaskMutation) ResetErrorType

func (m *AgentTaskMutation) ResetErrorType()

ResetErrorType resets all changes to the "error_type" field.

func (*AgentTaskMutation) ResetEvents

func (m *AgentTaskMutation) ResetEvents()

ResetEvents resets all changes to the "events" edge.

func (*AgentTaskMutation) ResetField

func (m *AgentTaskMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*AgentTaskMutation) ResetInput

func (m *AgentTaskMutation) ResetInput()

ResetInput resets all changes to the "input" field.

func (*AgentTaskMutation) ResetLlmCallCount

func (m *AgentTaskMutation) ResetLlmCallCount()

ResetLlmCallCount resets all changes to the "llm_call_count" field.

func (*AgentTaskMutation) ResetMetadata

func (m *AgentTaskMutation) ResetMetadata()

ResetMetadata resets all changes to the "metadata" field.

func (*AgentTaskMutation) ResetName

func (m *AgentTaskMutation) ResetName()

ResetName resets all changes to the "name" field.

func (*AgentTaskMutation) ResetOutput

func (m *AgentTaskMutation) ResetOutput()

ResetOutput resets all changes to the "output" field.

func (*AgentTaskMutation) ResetParentSpanID

func (m *AgentTaskMutation) ResetParentSpanID()

ResetParentSpanID resets all changes to the "parent_span_id" field.

func (*AgentTaskMutation) ResetRetryCount

func (m *AgentTaskMutation) ResetRetryCount()

ResetRetryCount resets all changes to the "retry_count" field.

func (*AgentTaskMutation) ResetSpanID

func (m *AgentTaskMutation) ResetSpanID()

ResetSpanID resets all changes to the "span_id" field.

func (*AgentTaskMutation) ResetStartedAt

func (m *AgentTaskMutation) ResetStartedAt()

ResetStartedAt resets all changes to the "started_at" field.

func (*AgentTaskMutation) ResetStatus

func (m *AgentTaskMutation) ResetStatus()

ResetStatus resets all changes to the "status" field.

func (*AgentTaskMutation) ResetTaskType

func (m *AgentTaskMutation) ResetTaskType()

ResetTaskType resets all changes to the "task_type" field.

func (*AgentTaskMutation) ResetTokensCompletion

func (m *AgentTaskMutation) ResetTokensCompletion()

ResetTokensCompletion resets all changes to the "tokens_completion" field.

func (*AgentTaskMutation) ResetTokensPrompt

func (m *AgentTaskMutation) ResetTokensPrompt()

ResetTokensPrompt resets all changes to the "tokens_prompt" field.

func (*AgentTaskMutation) ResetTokensTotal

func (m *AgentTaskMutation) ResetTokensTotal()

ResetTokensTotal resets all changes to the "tokens_total" field.

func (*AgentTaskMutation) ResetToolCallCount

func (m *AgentTaskMutation) ResetToolCallCount()

ResetToolCallCount resets all changes to the "tool_call_count" field.

func (*AgentTaskMutation) ResetToolInvocations

func (m *AgentTaskMutation) ResetToolInvocations()

ResetToolInvocations resets all changes to the "tool_invocations" edge.

func (*AgentTaskMutation) ResetTraceID

func (m *AgentTaskMutation) ResetTraceID()

ResetTraceID resets all changes to the "trace_id" field.

func (*AgentTaskMutation) ResetUpdatedAt

func (m *AgentTaskMutation) ResetUpdatedAt()

ResetUpdatedAt resets all changes to the "updated_at" field.

func (*AgentTaskMutation) ResetWorkflow

func (m *AgentTaskMutation) ResetWorkflow()

ResetWorkflow resets all changes to the "workflow" edge.

func (*AgentTaskMutation) ResetWorkflowID

func (m *AgentTaskMutation) ResetWorkflowID()

ResetWorkflowID resets all changes to the "workflow_id" field.

func (*AgentTaskMutation) RetryCount

func (m *AgentTaskMutation) RetryCount() (r int, exists bool)

RetryCount returns the value of the "retry_count" field in the mutation.

func (*AgentTaskMutation) SetAgentID

func (m *AgentTaskMutation) SetAgentID(s string)

SetAgentID sets the "agent_id" field.

func (*AgentTaskMutation) SetAgentType

func (m *AgentTaskMutation) SetAgentType(s string)

SetAgentType sets the "agent_type" field.

func (*AgentTaskMutation) SetCostUsd

func (m *AgentTaskMutation) SetCostUsd(f float64)

SetCostUsd sets the "cost_usd" field.

func (*AgentTaskMutation) SetCreatedAt

func (m *AgentTaskMutation) SetCreatedAt(t time.Time)

SetCreatedAt sets the "created_at" field.

func (*AgentTaskMutation) SetDurationMs

func (m *AgentTaskMutation) SetDurationMs(i int64)

SetDurationMs sets the "duration_ms" field.

func (*AgentTaskMutation) SetEndedAt

func (m *AgentTaskMutation) SetEndedAt(t time.Time)

SetEndedAt sets the "ended_at" field.

func (*AgentTaskMutation) SetErrorMessage

func (m *AgentTaskMutation) SetErrorMessage(s string)

SetErrorMessage sets the "error_message" field.

func (*AgentTaskMutation) SetErrorType

func (m *AgentTaskMutation) SetErrorType(s string)

SetErrorType sets the "error_type" field.

func (*AgentTaskMutation) SetField

func (m *AgentTaskMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*AgentTaskMutation) SetID

func (m *AgentTaskMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of AgentTask entities.

func (*AgentTaskMutation) SetInput

func (m *AgentTaskMutation) SetInput(value map[string]interface{})

SetInput sets the "input" field.

func (*AgentTaskMutation) SetLlmCallCount

func (m *AgentTaskMutation) SetLlmCallCount(i int)

SetLlmCallCount sets the "llm_call_count" field.

func (*AgentTaskMutation) SetMetadata

func (m *AgentTaskMutation) SetMetadata(value map[string]interface{})

SetMetadata sets the "metadata" field.

func (*AgentTaskMutation) SetName

func (m *AgentTaskMutation) SetName(s string)

SetName sets the "name" field.

func (*AgentTaskMutation) SetOp

func (m *AgentTaskMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*AgentTaskMutation) SetOutput

func (m *AgentTaskMutation) SetOutput(value map[string]interface{})

SetOutput sets the "output" field.

func (*AgentTaskMutation) SetParentSpanID

func (m *AgentTaskMutation) SetParentSpanID(s string)

SetParentSpanID sets the "parent_span_id" field.

func (*AgentTaskMutation) SetRetryCount

func (m *AgentTaskMutation) SetRetryCount(i int)

SetRetryCount sets the "retry_count" field.

func (*AgentTaskMutation) SetSpanID

func (m *AgentTaskMutation) SetSpanID(s string)

SetSpanID sets the "span_id" field.

func (*AgentTaskMutation) SetStartedAt

func (m *AgentTaskMutation) SetStartedAt(t time.Time)

SetStartedAt sets the "started_at" field.

func (*AgentTaskMutation) SetStatus

func (m *AgentTaskMutation) SetStatus(s string)

SetStatus sets the "status" field.

func (*AgentTaskMutation) SetTaskType

func (m *AgentTaskMutation) SetTaskType(s string)

SetTaskType sets the "task_type" field.

func (*AgentTaskMutation) SetTokensCompletion

func (m *AgentTaskMutation) SetTokensCompletion(i int)

SetTokensCompletion sets the "tokens_completion" field.

func (*AgentTaskMutation) SetTokensPrompt

func (m *AgentTaskMutation) SetTokensPrompt(i int)

SetTokensPrompt sets the "tokens_prompt" field.

func (*AgentTaskMutation) SetTokensTotal

func (m *AgentTaskMutation) SetTokensTotal(i int)

SetTokensTotal sets the "tokens_total" field.

func (*AgentTaskMutation) SetToolCallCount

func (m *AgentTaskMutation) SetToolCallCount(i int)

SetToolCallCount sets the "tool_call_count" field.

func (*AgentTaskMutation) SetTraceID

func (m *AgentTaskMutation) SetTraceID(s string)

SetTraceID sets the "trace_id" field.

func (*AgentTaskMutation) SetUpdatedAt

func (m *AgentTaskMutation) SetUpdatedAt(t time.Time)

SetUpdatedAt sets the "updated_at" field.

func (*AgentTaskMutation) SetWorkflowID

func (m *AgentTaskMutation) SetWorkflowID(s string)

SetWorkflowID sets the "workflow_id" field.

func (*AgentTaskMutation) SpanID

func (m *AgentTaskMutation) SpanID() (r string, exists bool)

SpanID returns the value of the "span_id" field in the mutation.

func (*AgentTaskMutation) SpanIDCleared

func (m *AgentTaskMutation) SpanIDCleared() bool

SpanIDCleared returns if the "span_id" field was cleared in this mutation.

func (*AgentTaskMutation) StartedAt

func (m *AgentTaskMutation) StartedAt() (r time.Time, exists bool)

StartedAt returns the value of the "started_at" field in the mutation.

func (*AgentTaskMutation) Status

func (m *AgentTaskMutation) Status() (r string, exists bool)

Status returns the value of the "status" field in the mutation.

func (*AgentTaskMutation) TaskType

func (m *AgentTaskMutation) TaskType() (r string, exists bool)

TaskType returns the value of the "task_type" field in the mutation.

func (*AgentTaskMutation) TokensCompletion

func (m *AgentTaskMutation) TokensCompletion() (r int, exists bool)

TokensCompletion returns the value of the "tokens_completion" field in the mutation.

func (*AgentTaskMutation) TokensPrompt

func (m *AgentTaskMutation) TokensPrompt() (r int, exists bool)

TokensPrompt returns the value of the "tokens_prompt" field in the mutation.

func (*AgentTaskMutation) TokensTotal

func (m *AgentTaskMutation) TokensTotal() (r int, exists bool)

TokensTotal returns the value of the "tokens_total" field in the mutation.

func (*AgentTaskMutation) ToolCallCount

func (m *AgentTaskMutation) ToolCallCount() (r int, exists bool)

ToolCallCount returns the value of the "tool_call_count" field in the mutation.

func (*AgentTaskMutation) ToolInvocationsCleared

func (m *AgentTaskMutation) ToolInvocationsCleared() bool

ToolInvocationsCleared reports if the "tool_invocations" edge to the ToolInvocation entity was cleared.

func (*AgentTaskMutation) ToolInvocationsIDs

func (m *AgentTaskMutation) ToolInvocationsIDs() (ids []string)

ToolInvocationsIDs returns the "tool_invocations" edge IDs in the mutation.

func (*AgentTaskMutation) TraceID

func (m *AgentTaskMutation) TraceID() (r string, exists bool)

TraceID returns the value of the "trace_id" field in the mutation.

func (*AgentTaskMutation) TraceIDCleared

func (m *AgentTaskMutation) TraceIDCleared() bool

TraceIDCleared returns if the "trace_id" field was cleared in this mutation.

func (AgentTaskMutation) Tx

func (m AgentTaskMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*AgentTaskMutation) Type

func (m *AgentTaskMutation) Type() string

Type returns the node type of this mutation (AgentTask).

func (*AgentTaskMutation) UpdatedAt

func (m *AgentTaskMutation) UpdatedAt() (r time.Time, exists bool)

UpdatedAt returns the value of the "updated_at" field in the mutation.

func (*AgentTaskMutation) Where

func (m *AgentTaskMutation) Where(ps ...predicate.AgentTask)

Where appends a list predicates to the AgentTaskMutation builder.

func (*AgentTaskMutation) WhereP

func (m *AgentTaskMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the AgentTaskMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

func (*AgentTaskMutation) WorkflowCleared

func (m *AgentTaskMutation) WorkflowCleared() bool

WorkflowCleared reports if the "workflow" edge to the Workflow entity was cleared.

func (*AgentTaskMutation) WorkflowID

func (m *AgentTaskMutation) WorkflowID() (r string, exists bool)

WorkflowID returns the value of the "workflow_id" field in the mutation.

func (*AgentTaskMutation) WorkflowIDCleared

func (m *AgentTaskMutation) WorkflowIDCleared() bool

WorkflowIDCleared returns if the "workflow_id" field was cleared in this mutation.

func (*AgentTaskMutation) WorkflowIDs

func (m *AgentTaskMutation) WorkflowIDs() (ids []string)

WorkflowIDs returns the "workflow" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use WorkflowID instead. It exists only for internal usage by the builders.

type AgentTaskQuery

type AgentTaskQuery struct {
	// contains filtered or unexported fields
}

AgentTaskQuery is the builder for querying AgentTask entities.

func (*AgentTaskQuery) Aggregate

func (atq *AgentTaskQuery) Aggregate(fns ...AggregateFunc) *AgentTaskSelect

Aggregate returns a AgentTaskSelect configured with the given aggregations.

func (*AgentTaskQuery) All

func (atq *AgentTaskQuery) All(ctx context.Context) ([]*AgentTask, error)

All executes the query and returns a list of AgentTasks.

func (*AgentTaskQuery) AllX

func (atq *AgentTaskQuery) AllX(ctx context.Context) []*AgentTask

AllX is like All, but panics if an error occurs.

func (*AgentTaskQuery) Clone

func (atq *AgentTaskQuery) Clone() *AgentTaskQuery

Clone returns a duplicate of the AgentTaskQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*AgentTaskQuery) Count

func (atq *AgentTaskQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*AgentTaskQuery) CountX

func (atq *AgentTaskQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*AgentTaskQuery) Exist

func (atq *AgentTaskQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*AgentTaskQuery) ExistX

func (atq *AgentTaskQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*AgentTaskQuery) First

func (atq *AgentTaskQuery) First(ctx context.Context) (*AgentTask, error)

First returns the first AgentTask entity from the query. Returns a *NotFoundError when no AgentTask was found.

func (*AgentTaskQuery) FirstID

func (atq *AgentTaskQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first AgentTask ID from the query. Returns a *NotFoundError when no AgentTask ID was found.

func (*AgentTaskQuery) FirstIDX

func (atq *AgentTaskQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*AgentTaskQuery) FirstX

func (atq *AgentTaskQuery) FirstX(ctx context.Context) *AgentTask

FirstX is like First, but panics if an error occurs.

func (*AgentTaskQuery) GroupBy

func (atq *AgentTaskQuery) GroupBy(field string, fields ...string) *AgentTaskGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	WorkflowID string `json:"workflow_id,omitempty"`
	Count int `json:"count,omitempty"`
}

client.AgentTask.Query().
	GroupBy(agenttask.FieldWorkflowID).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*AgentTaskQuery) IDs

func (atq *AgentTaskQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of AgentTask IDs.

func (*AgentTaskQuery) IDsX

func (atq *AgentTaskQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*AgentTaskQuery) Limit

func (atq *AgentTaskQuery) Limit(limit int) *AgentTaskQuery

Limit the number of records to be returned by this query.

func (*AgentTaskQuery) Offset

func (atq *AgentTaskQuery) Offset(offset int) *AgentTaskQuery

Offset to start from.

func (*AgentTaskQuery) Only

func (atq *AgentTaskQuery) Only(ctx context.Context) (*AgentTask, error)

Only returns a single AgentTask entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one AgentTask entity is found. Returns a *NotFoundError when no AgentTask entities are found.

func (*AgentTaskQuery) OnlyID

func (atq *AgentTaskQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only AgentTask ID in the query. Returns a *NotSingularError when more than one AgentTask ID is found. Returns a *NotFoundError when no entities are found.

func (*AgentTaskQuery) OnlyIDX

func (atq *AgentTaskQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*AgentTaskQuery) OnlyX

func (atq *AgentTaskQuery) OnlyX(ctx context.Context) *AgentTask

OnlyX is like Only, but panics if an error occurs.

func (*AgentTaskQuery) Order

Order specifies how the records should be ordered.

func (*AgentTaskQuery) QueryEvents

func (atq *AgentTaskQuery) QueryEvents() *AgentEventQuery

QueryEvents chains the current query on the "events" edge.

func (*AgentTaskQuery) QueryToolInvocations

func (atq *AgentTaskQuery) QueryToolInvocations() *ToolInvocationQuery

QueryToolInvocations chains the current query on the "tool_invocations" edge.

func (*AgentTaskQuery) QueryWorkflow

func (atq *AgentTaskQuery) QueryWorkflow() *WorkflowQuery

QueryWorkflow chains the current query on the "workflow" edge.

func (*AgentTaskQuery) Select

func (atq *AgentTaskQuery) Select(fields ...string) *AgentTaskSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	WorkflowID string `json:"workflow_id,omitempty"`
}

client.AgentTask.Query().
	Select(agenttask.FieldWorkflowID).
	Scan(ctx, &v)

func (*AgentTaskQuery) Unique

func (atq *AgentTaskQuery) Unique(unique bool) *AgentTaskQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*AgentTaskQuery) Where

func (atq *AgentTaskQuery) Where(ps ...predicate.AgentTask) *AgentTaskQuery

Where adds a new predicate for the AgentTaskQuery builder.

func (*AgentTaskQuery) WithEvents

func (atq *AgentTaskQuery) WithEvents(opts ...func(*AgentEventQuery)) *AgentTaskQuery

WithEvents tells the query-builder to eager-load the nodes that are connected to the "events" edge. The optional arguments are used to configure the query builder of the edge.

func (*AgentTaskQuery) WithToolInvocations

func (atq *AgentTaskQuery) WithToolInvocations(opts ...func(*ToolInvocationQuery)) *AgentTaskQuery

WithToolInvocations tells the query-builder to eager-load the nodes that are connected to the "tool_invocations" edge. The optional arguments are used to configure the query builder of the edge.

func (*AgentTaskQuery) WithWorkflow

func (atq *AgentTaskQuery) WithWorkflow(opts ...func(*WorkflowQuery)) *AgentTaskQuery

WithWorkflow tells the query-builder to eager-load the nodes that are connected to the "workflow" edge. The optional arguments are used to configure the query builder of the edge.

type AgentTaskSelect

type AgentTaskSelect struct {
	*AgentTaskQuery
	// contains filtered or unexported fields
}

AgentTaskSelect is the builder for selecting fields of AgentTask entities.

func (*AgentTaskSelect) Aggregate

func (ats *AgentTaskSelect) Aggregate(fns ...AggregateFunc) *AgentTaskSelect

Aggregate adds the given aggregation functions to the selector query.

func (*AgentTaskSelect) Bool

func (s *AgentTaskSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*AgentTaskSelect) BoolX

func (s *AgentTaskSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*AgentTaskSelect) Bools

func (s *AgentTaskSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*AgentTaskSelect) BoolsX

func (s *AgentTaskSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*AgentTaskSelect) Float64

func (s *AgentTaskSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*AgentTaskSelect) Float64X

func (s *AgentTaskSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*AgentTaskSelect) Float64s

func (s *AgentTaskSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*AgentTaskSelect) Float64sX

func (s *AgentTaskSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*AgentTaskSelect) Int

func (s *AgentTaskSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*AgentTaskSelect) IntX

func (s *AgentTaskSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*AgentTaskSelect) Ints

func (s *AgentTaskSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*AgentTaskSelect) IntsX

func (s *AgentTaskSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*AgentTaskSelect) Scan

func (ats *AgentTaskSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*AgentTaskSelect) ScanX

func (s *AgentTaskSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*AgentTaskSelect) String

func (s *AgentTaskSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*AgentTaskSelect) StringX

func (s *AgentTaskSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*AgentTaskSelect) Strings

func (s *AgentTaskSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*AgentTaskSelect) StringsX

func (s *AgentTaskSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type AgentTaskUpdate

type AgentTaskUpdate struct {
	// contains filtered or unexported fields
}

AgentTaskUpdate is the builder for updating AgentTask entities.

func (*AgentTaskUpdate) AddCostUsd

func (atu *AgentTaskUpdate) AddCostUsd(f float64) *AgentTaskUpdate

AddCostUsd adds f to the "cost_usd" field.

func (*AgentTaskUpdate) AddDurationMs

func (atu *AgentTaskUpdate) AddDurationMs(i int64) *AgentTaskUpdate

AddDurationMs adds i to the "duration_ms" field.

func (*AgentTaskUpdate) AddEventIDs

func (atu *AgentTaskUpdate) AddEventIDs(ids ...string) *AgentTaskUpdate

AddEventIDs adds the "events" edge to the AgentEvent entity by IDs.

func (*AgentTaskUpdate) AddEvents

func (atu *AgentTaskUpdate) AddEvents(a ...*AgentEvent) *AgentTaskUpdate

AddEvents adds the "events" edges to the AgentEvent entity.

func (*AgentTaskUpdate) AddLlmCallCount

func (atu *AgentTaskUpdate) AddLlmCallCount(i int) *AgentTaskUpdate

AddLlmCallCount adds i to the "llm_call_count" field.

func (*AgentTaskUpdate) AddRetryCount

func (atu *AgentTaskUpdate) AddRetryCount(i int) *AgentTaskUpdate

AddRetryCount adds i to the "retry_count" field.

func (*AgentTaskUpdate) AddTokensCompletion

func (atu *AgentTaskUpdate) AddTokensCompletion(i int) *AgentTaskUpdate

AddTokensCompletion adds i to the "tokens_completion" field.

func (*AgentTaskUpdate) AddTokensPrompt

func (atu *AgentTaskUpdate) AddTokensPrompt(i int) *AgentTaskUpdate

AddTokensPrompt adds i to the "tokens_prompt" field.

func (*AgentTaskUpdate) AddTokensTotal

func (atu *AgentTaskUpdate) AddTokensTotal(i int) *AgentTaskUpdate

AddTokensTotal adds i to the "tokens_total" field.

func (*AgentTaskUpdate) AddToolCallCount

func (atu *AgentTaskUpdate) AddToolCallCount(i int) *AgentTaskUpdate

AddToolCallCount adds i to the "tool_call_count" field.

func (*AgentTaskUpdate) AddToolInvocationIDs

func (atu *AgentTaskUpdate) AddToolInvocationIDs(ids ...string) *AgentTaskUpdate

AddToolInvocationIDs adds the "tool_invocations" edge to the ToolInvocation entity by IDs.

func (*AgentTaskUpdate) AddToolInvocations

func (atu *AgentTaskUpdate) AddToolInvocations(t ...*ToolInvocation) *AgentTaskUpdate

AddToolInvocations adds the "tool_invocations" edges to the ToolInvocation entity.

func (*AgentTaskUpdate) ClearAgentType

func (atu *AgentTaskUpdate) ClearAgentType() *AgentTaskUpdate

ClearAgentType clears the value of the "agent_type" field.

func (*AgentTaskUpdate) ClearDurationMs

func (atu *AgentTaskUpdate) ClearDurationMs() *AgentTaskUpdate

ClearDurationMs clears the value of the "duration_ms" field.

func (*AgentTaskUpdate) ClearEndedAt

func (atu *AgentTaskUpdate) ClearEndedAt() *AgentTaskUpdate

ClearEndedAt clears the value of the "ended_at" field.

func (*AgentTaskUpdate) ClearErrorMessage

func (atu *AgentTaskUpdate) ClearErrorMessage() *AgentTaskUpdate

ClearErrorMessage clears the value of the "error_message" field.

func (*AgentTaskUpdate) ClearErrorType

func (atu *AgentTaskUpdate) ClearErrorType() *AgentTaskUpdate

ClearErrorType clears the value of the "error_type" field.

func (*AgentTaskUpdate) ClearEvents

func (atu *AgentTaskUpdate) ClearEvents() *AgentTaskUpdate

ClearEvents clears all "events" edges to the AgentEvent entity.

func (*AgentTaskUpdate) ClearInput

func (atu *AgentTaskUpdate) ClearInput() *AgentTaskUpdate

ClearInput clears the value of the "input" field.

func (*AgentTaskUpdate) ClearMetadata

func (atu *AgentTaskUpdate) ClearMetadata() *AgentTaskUpdate

ClearMetadata clears the value of the "metadata" field.

func (*AgentTaskUpdate) ClearOutput

func (atu *AgentTaskUpdate) ClearOutput() *AgentTaskUpdate

ClearOutput clears the value of the "output" field.

func (*AgentTaskUpdate) ClearParentSpanID

func (atu *AgentTaskUpdate) ClearParentSpanID() *AgentTaskUpdate

ClearParentSpanID clears the value of the "parent_span_id" field.

func (*AgentTaskUpdate) ClearSpanID

func (atu *AgentTaskUpdate) ClearSpanID() *AgentTaskUpdate

ClearSpanID clears the value of the "span_id" field.

func (*AgentTaskUpdate) ClearToolInvocations

func (atu *AgentTaskUpdate) ClearToolInvocations() *AgentTaskUpdate

ClearToolInvocations clears all "tool_invocations" edges to the ToolInvocation entity.

func (*AgentTaskUpdate) ClearTraceID

func (atu *AgentTaskUpdate) ClearTraceID() *AgentTaskUpdate

ClearTraceID clears the value of the "trace_id" field.

func (*AgentTaskUpdate) ClearWorkflow

func (atu *AgentTaskUpdate) ClearWorkflow() *AgentTaskUpdate

ClearWorkflow clears the "workflow" edge to the Workflow entity.

func (*AgentTaskUpdate) ClearWorkflowID

func (atu *AgentTaskUpdate) ClearWorkflowID() *AgentTaskUpdate

ClearWorkflowID clears the value of the "workflow_id" field.

func (*AgentTaskUpdate) Exec

func (atu *AgentTaskUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*AgentTaskUpdate) ExecX

func (atu *AgentTaskUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*AgentTaskUpdate) Mutation

func (atu *AgentTaskUpdate) Mutation() *AgentTaskMutation

Mutation returns the AgentTaskMutation object of the builder.

func (*AgentTaskUpdate) RemoveEventIDs

func (atu *AgentTaskUpdate) RemoveEventIDs(ids ...string) *AgentTaskUpdate

RemoveEventIDs removes the "events" edge to AgentEvent entities by IDs.

func (*AgentTaskUpdate) RemoveEvents

func (atu *AgentTaskUpdate) RemoveEvents(a ...*AgentEvent) *AgentTaskUpdate

RemoveEvents removes "events" edges to AgentEvent entities.

func (*AgentTaskUpdate) RemoveToolInvocationIDs

func (atu *AgentTaskUpdate) RemoveToolInvocationIDs(ids ...string) *AgentTaskUpdate

RemoveToolInvocationIDs removes the "tool_invocations" edge to ToolInvocation entities by IDs.

func (*AgentTaskUpdate) RemoveToolInvocations

func (atu *AgentTaskUpdate) RemoveToolInvocations(t ...*ToolInvocation) *AgentTaskUpdate

RemoveToolInvocations removes "tool_invocations" edges to ToolInvocation entities.

func (*AgentTaskUpdate) Save

func (atu *AgentTaskUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*AgentTaskUpdate) SaveX

func (atu *AgentTaskUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*AgentTaskUpdate) SetAgentID

func (atu *AgentTaskUpdate) SetAgentID(s string) *AgentTaskUpdate

SetAgentID sets the "agent_id" field.

func (*AgentTaskUpdate) SetAgentType

func (atu *AgentTaskUpdate) SetAgentType(s string) *AgentTaskUpdate

SetAgentType sets the "agent_type" field.

func (*AgentTaskUpdate) SetCostUsd

func (atu *AgentTaskUpdate) SetCostUsd(f float64) *AgentTaskUpdate

SetCostUsd sets the "cost_usd" field.

func (*AgentTaskUpdate) SetDurationMs

func (atu *AgentTaskUpdate) SetDurationMs(i int64) *AgentTaskUpdate

SetDurationMs sets the "duration_ms" field.

func (*AgentTaskUpdate) SetEndedAt

func (atu *AgentTaskUpdate) SetEndedAt(t time.Time) *AgentTaskUpdate

SetEndedAt sets the "ended_at" field.

func (*AgentTaskUpdate) SetErrorMessage

func (atu *AgentTaskUpdate) SetErrorMessage(s string) *AgentTaskUpdate

SetErrorMessage sets the "error_message" field.

func (*AgentTaskUpdate) SetErrorType

func (atu *AgentTaskUpdate) SetErrorType(s string) *AgentTaskUpdate

SetErrorType sets the "error_type" field.

func (*AgentTaskUpdate) SetInput

func (atu *AgentTaskUpdate) SetInput(m map[string]interface{}) *AgentTaskUpdate

SetInput sets the "input" field.

func (*AgentTaskUpdate) SetLlmCallCount

func (atu *AgentTaskUpdate) SetLlmCallCount(i int) *AgentTaskUpdate

SetLlmCallCount sets the "llm_call_count" field.

func (*AgentTaskUpdate) SetMetadata

func (atu *AgentTaskUpdate) SetMetadata(m map[string]interface{}) *AgentTaskUpdate

SetMetadata sets the "metadata" field.

func (*AgentTaskUpdate) SetName

func (atu *AgentTaskUpdate) SetName(s string) *AgentTaskUpdate

SetName sets the "name" field.

func (*AgentTaskUpdate) SetNillableAgentID

func (atu *AgentTaskUpdate) SetNillableAgentID(s *string) *AgentTaskUpdate

SetNillableAgentID sets the "agent_id" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableAgentType

func (atu *AgentTaskUpdate) SetNillableAgentType(s *string) *AgentTaskUpdate

SetNillableAgentType sets the "agent_type" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableCostUsd

func (atu *AgentTaskUpdate) SetNillableCostUsd(f *float64) *AgentTaskUpdate

SetNillableCostUsd sets the "cost_usd" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableDurationMs

func (atu *AgentTaskUpdate) SetNillableDurationMs(i *int64) *AgentTaskUpdate

SetNillableDurationMs sets the "duration_ms" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableEndedAt

func (atu *AgentTaskUpdate) SetNillableEndedAt(t *time.Time) *AgentTaskUpdate

SetNillableEndedAt sets the "ended_at" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableErrorMessage

func (atu *AgentTaskUpdate) SetNillableErrorMessage(s *string) *AgentTaskUpdate

SetNillableErrorMessage sets the "error_message" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableErrorType

func (atu *AgentTaskUpdate) SetNillableErrorType(s *string) *AgentTaskUpdate

SetNillableErrorType sets the "error_type" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableLlmCallCount

func (atu *AgentTaskUpdate) SetNillableLlmCallCount(i *int) *AgentTaskUpdate

SetNillableLlmCallCount sets the "llm_call_count" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableName

func (atu *AgentTaskUpdate) SetNillableName(s *string) *AgentTaskUpdate

SetNillableName sets the "name" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableParentSpanID

func (atu *AgentTaskUpdate) SetNillableParentSpanID(s *string) *AgentTaskUpdate

SetNillableParentSpanID sets the "parent_span_id" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableRetryCount

func (atu *AgentTaskUpdate) SetNillableRetryCount(i *int) *AgentTaskUpdate

SetNillableRetryCount sets the "retry_count" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableSpanID

func (atu *AgentTaskUpdate) SetNillableSpanID(s *string) *AgentTaskUpdate

SetNillableSpanID sets the "span_id" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableStatus

func (atu *AgentTaskUpdate) SetNillableStatus(s *string) *AgentTaskUpdate

SetNillableStatus sets the "status" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableTaskType

func (atu *AgentTaskUpdate) SetNillableTaskType(s *string) *AgentTaskUpdate

SetNillableTaskType sets the "task_type" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableTokensCompletion

func (atu *AgentTaskUpdate) SetNillableTokensCompletion(i *int) *AgentTaskUpdate

SetNillableTokensCompletion sets the "tokens_completion" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableTokensPrompt

func (atu *AgentTaskUpdate) SetNillableTokensPrompt(i *int) *AgentTaskUpdate

SetNillableTokensPrompt sets the "tokens_prompt" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableTokensTotal

func (atu *AgentTaskUpdate) SetNillableTokensTotal(i *int) *AgentTaskUpdate

SetNillableTokensTotal sets the "tokens_total" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableToolCallCount

func (atu *AgentTaskUpdate) SetNillableToolCallCount(i *int) *AgentTaskUpdate

SetNillableToolCallCount sets the "tool_call_count" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableTraceID

func (atu *AgentTaskUpdate) SetNillableTraceID(s *string) *AgentTaskUpdate

SetNillableTraceID sets the "trace_id" field if the given value is not nil.

func (*AgentTaskUpdate) SetNillableWorkflowID

func (atu *AgentTaskUpdate) SetNillableWorkflowID(s *string) *AgentTaskUpdate

SetNillableWorkflowID sets the "workflow_id" field if the given value is not nil.

func (*AgentTaskUpdate) SetOutput

func (atu *AgentTaskUpdate) SetOutput(m map[string]interface{}) *AgentTaskUpdate

SetOutput sets the "output" field.

func (*AgentTaskUpdate) SetParentSpanID

func (atu *AgentTaskUpdate) SetParentSpanID(s string) *AgentTaskUpdate

SetParentSpanID sets the "parent_span_id" field.

func (*AgentTaskUpdate) SetRetryCount

func (atu *AgentTaskUpdate) SetRetryCount(i int) *AgentTaskUpdate

SetRetryCount sets the "retry_count" field.

func (*AgentTaskUpdate) SetSpanID

func (atu *AgentTaskUpdate) SetSpanID(s string) *AgentTaskUpdate

SetSpanID sets the "span_id" field.

func (*AgentTaskUpdate) SetStatus

func (atu *AgentTaskUpdate) SetStatus(s string) *AgentTaskUpdate

SetStatus sets the "status" field.

func (*AgentTaskUpdate) SetTaskType

func (atu *AgentTaskUpdate) SetTaskType(s string) *AgentTaskUpdate

SetTaskType sets the "task_type" field.

func (*AgentTaskUpdate) SetTokensCompletion

func (atu *AgentTaskUpdate) SetTokensCompletion(i int) *AgentTaskUpdate

SetTokensCompletion sets the "tokens_completion" field.

func (*AgentTaskUpdate) SetTokensPrompt

func (atu *AgentTaskUpdate) SetTokensPrompt(i int) *AgentTaskUpdate

SetTokensPrompt sets the "tokens_prompt" field.

func (*AgentTaskUpdate) SetTokensTotal

func (atu *AgentTaskUpdate) SetTokensTotal(i int) *AgentTaskUpdate

SetTokensTotal sets the "tokens_total" field.

func (*AgentTaskUpdate) SetToolCallCount

func (atu *AgentTaskUpdate) SetToolCallCount(i int) *AgentTaskUpdate

SetToolCallCount sets the "tool_call_count" field.

func (*AgentTaskUpdate) SetTraceID

func (atu *AgentTaskUpdate) SetTraceID(s string) *AgentTaskUpdate

SetTraceID sets the "trace_id" field.

func (*AgentTaskUpdate) SetUpdatedAt

func (atu *AgentTaskUpdate) SetUpdatedAt(t time.Time) *AgentTaskUpdate

SetUpdatedAt sets the "updated_at" field.

func (*AgentTaskUpdate) SetWorkflow

func (atu *AgentTaskUpdate) SetWorkflow(w *Workflow) *AgentTaskUpdate

SetWorkflow sets the "workflow" edge to the Workflow entity.

func (*AgentTaskUpdate) SetWorkflowID

func (atu *AgentTaskUpdate) SetWorkflowID(s string) *AgentTaskUpdate

SetWorkflowID sets the "workflow_id" field.

func (*AgentTaskUpdate) Where

Where appends a list predicates to the AgentTaskUpdate builder.

type AgentTaskUpdateOne

type AgentTaskUpdateOne struct {
	// contains filtered or unexported fields
}

AgentTaskUpdateOne is the builder for updating a single AgentTask entity.

func (*AgentTaskUpdateOne) AddCostUsd

func (atuo *AgentTaskUpdateOne) AddCostUsd(f float64) *AgentTaskUpdateOne

AddCostUsd adds f to the "cost_usd" field.

func (*AgentTaskUpdateOne) AddDurationMs

func (atuo *AgentTaskUpdateOne) AddDurationMs(i int64) *AgentTaskUpdateOne

AddDurationMs adds i to the "duration_ms" field.

func (*AgentTaskUpdateOne) AddEventIDs

func (atuo *AgentTaskUpdateOne) AddEventIDs(ids ...string) *AgentTaskUpdateOne

AddEventIDs adds the "events" edge to the AgentEvent entity by IDs.

func (*AgentTaskUpdateOne) AddEvents

func (atuo *AgentTaskUpdateOne) AddEvents(a ...*AgentEvent) *AgentTaskUpdateOne

AddEvents adds the "events" edges to the AgentEvent entity.

func (*AgentTaskUpdateOne) AddLlmCallCount

func (atuo *AgentTaskUpdateOne) AddLlmCallCount(i int) *AgentTaskUpdateOne

AddLlmCallCount adds i to the "llm_call_count" field.

func (*AgentTaskUpdateOne) AddRetryCount

func (atuo *AgentTaskUpdateOne) AddRetryCount(i int) *AgentTaskUpdateOne

AddRetryCount adds i to the "retry_count" field.

func (*AgentTaskUpdateOne) AddTokensCompletion

func (atuo *AgentTaskUpdateOne) AddTokensCompletion(i int) *AgentTaskUpdateOne

AddTokensCompletion adds i to the "tokens_completion" field.

func (*AgentTaskUpdateOne) AddTokensPrompt

func (atuo *AgentTaskUpdateOne) AddTokensPrompt(i int) *AgentTaskUpdateOne

AddTokensPrompt adds i to the "tokens_prompt" field.

func (*AgentTaskUpdateOne) AddTokensTotal

func (atuo *AgentTaskUpdateOne) AddTokensTotal(i int) *AgentTaskUpdateOne

AddTokensTotal adds i to the "tokens_total" field.

func (*AgentTaskUpdateOne) AddToolCallCount

func (atuo *AgentTaskUpdateOne) AddToolCallCount(i int) *AgentTaskUpdateOne

AddToolCallCount adds i to the "tool_call_count" field.

func (*AgentTaskUpdateOne) AddToolInvocationIDs

func (atuo *AgentTaskUpdateOne) AddToolInvocationIDs(ids ...string) *AgentTaskUpdateOne

AddToolInvocationIDs adds the "tool_invocations" edge to the ToolInvocation entity by IDs.

func (*AgentTaskUpdateOne) AddToolInvocations

func (atuo *AgentTaskUpdateOne) AddToolInvocations(t ...*ToolInvocation) *AgentTaskUpdateOne

AddToolInvocations adds the "tool_invocations" edges to the ToolInvocation entity.

func (*AgentTaskUpdateOne) ClearAgentType

func (atuo *AgentTaskUpdateOne) ClearAgentType() *AgentTaskUpdateOne

ClearAgentType clears the value of the "agent_type" field.

func (*AgentTaskUpdateOne) ClearDurationMs

func (atuo *AgentTaskUpdateOne) ClearDurationMs() *AgentTaskUpdateOne

ClearDurationMs clears the value of the "duration_ms" field.

func (*AgentTaskUpdateOne) ClearEndedAt

func (atuo *AgentTaskUpdateOne) ClearEndedAt() *AgentTaskUpdateOne

ClearEndedAt clears the value of the "ended_at" field.

func (*AgentTaskUpdateOne) ClearErrorMessage

func (atuo *AgentTaskUpdateOne) ClearErrorMessage() *AgentTaskUpdateOne

ClearErrorMessage clears the value of the "error_message" field.

func (*AgentTaskUpdateOne) ClearErrorType

func (atuo *AgentTaskUpdateOne) ClearErrorType() *AgentTaskUpdateOne

ClearErrorType clears the value of the "error_type" field.

func (*AgentTaskUpdateOne) ClearEvents

func (atuo *AgentTaskUpdateOne) ClearEvents() *AgentTaskUpdateOne

ClearEvents clears all "events" edges to the AgentEvent entity.

func (*AgentTaskUpdateOne) ClearInput

func (atuo *AgentTaskUpdateOne) ClearInput() *AgentTaskUpdateOne

ClearInput clears the value of the "input" field.

func (*AgentTaskUpdateOne) ClearMetadata

func (atuo *AgentTaskUpdateOne) ClearMetadata() *AgentTaskUpdateOne

ClearMetadata clears the value of the "metadata" field.

func (*AgentTaskUpdateOne) ClearOutput

func (atuo *AgentTaskUpdateOne) ClearOutput() *AgentTaskUpdateOne

ClearOutput clears the value of the "output" field.

func (*AgentTaskUpdateOne) ClearParentSpanID

func (atuo *AgentTaskUpdateOne) ClearParentSpanID() *AgentTaskUpdateOne

ClearParentSpanID clears the value of the "parent_span_id" field.

func (*AgentTaskUpdateOne) ClearSpanID

func (atuo *AgentTaskUpdateOne) ClearSpanID() *AgentTaskUpdateOne

ClearSpanID clears the value of the "span_id" field.

func (*AgentTaskUpdateOne) ClearToolInvocations

func (atuo *AgentTaskUpdateOne) ClearToolInvocations() *AgentTaskUpdateOne

ClearToolInvocations clears all "tool_invocations" edges to the ToolInvocation entity.

func (*AgentTaskUpdateOne) ClearTraceID

func (atuo *AgentTaskUpdateOne) ClearTraceID() *AgentTaskUpdateOne

ClearTraceID clears the value of the "trace_id" field.

func (*AgentTaskUpdateOne) ClearWorkflow

func (atuo *AgentTaskUpdateOne) ClearWorkflow() *AgentTaskUpdateOne

ClearWorkflow clears the "workflow" edge to the Workflow entity.

func (*AgentTaskUpdateOne) ClearWorkflowID

func (atuo *AgentTaskUpdateOne) ClearWorkflowID() *AgentTaskUpdateOne

ClearWorkflowID clears the value of the "workflow_id" field.

func (*AgentTaskUpdateOne) Exec

func (atuo *AgentTaskUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*AgentTaskUpdateOne) ExecX

func (atuo *AgentTaskUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*AgentTaskUpdateOne) Mutation

func (atuo *AgentTaskUpdateOne) Mutation() *AgentTaskMutation

Mutation returns the AgentTaskMutation object of the builder.

func (*AgentTaskUpdateOne) RemoveEventIDs

func (atuo *AgentTaskUpdateOne) RemoveEventIDs(ids ...string) *AgentTaskUpdateOne

RemoveEventIDs removes the "events" edge to AgentEvent entities by IDs.

func (*AgentTaskUpdateOne) RemoveEvents

func (atuo *AgentTaskUpdateOne) RemoveEvents(a ...*AgentEvent) *AgentTaskUpdateOne

RemoveEvents removes "events" edges to AgentEvent entities.

func (*AgentTaskUpdateOne) RemoveToolInvocationIDs

func (atuo *AgentTaskUpdateOne) RemoveToolInvocationIDs(ids ...string) *AgentTaskUpdateOne

RemoveToolInvocationIDs removes the "tool_invocations" edge to ToolInvocation entities by IDs.

func (*AgentTaskUpdateOne) RemoveToolInvocations

func (atuo *AgentTaskUpdateOne) RemoveToolInvocations(t ...*ToolInvocation) *AgentTaskUpdateOne

RemoveToolInvocations removes "tool_invocations" edges to ToolInvocation entities.

func (*AgentTaskUpdateOne) Save

func (atuo *AgentTaskUpdateOne) Save(ctx context.Context) (*AgentTask, error)

Save executes the query and returns the updated AgentTask entity.

func (*AgentTaskUpdateOne) SaveX

func (atuo *AgentTaskUpdateOne) SaveX(ctx context.Context) *AgentTask

SaveX is like Save, but panics if an error occurs.

func (*AgentTaskUpdateOne) Select

func (atuo *AgentTaskUpdateOne) Select(field string, fields ...string) *AgentTaskUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*AgentTaskUpdateOne) SetAgentID

func (atuo *AgentTaskUpdateOne) SetAgentID(s string) *AgentTaskUpdateOne

SetAgentID sets the "agent_id" field.

func (*AgentTaskUpdateOne) SetAgentType

func (atuo *AgentTaskUpdateOne) SetAgentType(s string) *AgentTaskUpdateOne

SetAgentType sets the "agent_type" field.

func (*AgentTaskUpdateOne) SetCostUsd

func (atuo *AgentTaskUpdateOne) SetCostUsd(f float64) *AgentTaskUpdateOne

SetCostUsd sets the "cost_usd" field.

func (*AgentTaskUpdateOne) SetDurationMs

func (atuo *AgentTaskUpdateOne) SetDurationMs(i int64) *AgentTaskUpdateOne

SetDurationMs sets the "duration_ms" field.

func (*AgentTaskUpdateOne) SetEndedAt

func (atuo *AgentTaskUpdateOne) SetEndedAt(t time.Time) *AgentTaskUpdateOne

SetEndedAt sets the "ended_at" field.

func (*AgentTaskUpdateOne) SetErrorMessage

func (atuo *AgentTaskUpdateOne) SetErrorMessage(s string) *AgentTaskUpdateOne

SetErrorMessage sets the "error_message" field.

func (*AgentTaskUpdateOne) SetErrorType

func (atuo *AgentTaskUpdateOne) SetErrorType(s string) *AgentTaskUpdateOne

SetErrorType sets the "error_type" field.

func (*AgentTaskUpdateOne) SetInput

func (atuo *AgentTaskUpdateOne) SetInput(m map[string]interface{}) *AgentTaskUpdateOne

SetInput sets the "input" field.

func (*AgentTaskUpdateOne) SetLlmCallCount

func (atuo *AgentTaskUpdateOne) SetLlmCallCount(i int) *AgentTaskUpdateOne

SetLlmCallCount sets the "llm_call_count" field.

func (*AgentTaskUpdateOne) SetMetadata

func (atuo *AgentTaskUpdateOne) SetMetadata(m map[string]interface{}) *AgentTaskUpdateOne

SetMetadata sets the "metadata" field.

func (*AgentTaskUpdateOne) SetName

func (atuo *AgentTaskUpdateOne) SetName(s string) *AgentTaskUpdateOne

SetName sets the "name" field.

func (*AgentTaskUpdateOne) SetNillableAgentID

func (atuo *AgentTaskUpdateOne) SetNillableAgentID(s *string) *AgentTaskUpdateOne

SetNillableAgentID sets the "agent_id" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableAgentType

func (atuo *AgentTaskUpdateOne) SetNillableAgentType(s *string) *AgentTaskUpdateOne

SetNillableAgentType sets the "agent_type" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableCostUsd

func (atuo *AgentTaskUpdateOne) SetNillableCostUsd(f *float64) *AgentTaskUpdateOne

SetNillableCostUsd sets the "cost_usd" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableDurationMs

func (atuo *AgentTaskUpdateOne) SetNillableDurationMs(i *int64) *AgentTaskUpdateOne

SetNillableDurationMs sets the "duration_ms" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableEndedAt

func (atuo *AgentTaskUpdateOne) SetNillableEndedAt(t *time.Time) *AgentTaskUpdateOne

SetNillableEndedAt sets the "ended_at" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableErrorMessage

func (atuo *AgentTaskUpdateOne) SetNillableErrorMessage(s *string) *AgentTaskUpdateOne

SetNillableErrorMessage sets the "error_message" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableErrorType

func (atuo *AgentTaskUpdateOne) SetNillableErrorType(s *string) *AgentTaskUpdateOne

SetNillableErrorType sets the "error_type" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableLlmCallCount

func (atuo *AgentTaskUpdateOne) SetNillableLlmCallCount(i *int) *AgentTaskUpdateOne

SetNillableLlmCallCount sets the "llm_call_count" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableName

func (atuo *AgentTaskUpdateOne) SetNillableName(s *string) *AgentTaskUpdateOne

SetNillableName sets the "name" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableParentSpanID

func (atuo *AgentTaskUpdateOne) SetNillableParentSpanID(s *string) *AgentTaskUpdateOne

SetNillableParentSpanID sets the "parent_span_id" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableRetryCount

func (atuo *AgentTaskUpdateOne) SetNillableRetryCount(i *int) *AgentTaskUpdateOne

SetNillableRetryCount sets the "retry_count" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableSpanID

func (atuo *AgentTaskUpdateOne) SetNillableSpanID(s *string) *AgentTaskUpdateOne

SetNillableSpanID sets the "span_id" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableStatus

func (atuo *AgentTaskUpdateOne) SetNillableStatus(s *string) *AgentTaskUpdateOne

SetNillableStatus sets the "status" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableTaskType

func (atuo *AgentTaskUpdateOne) SetNillableTaskType(s *string) *AgentTaskUpdateOne

SetNillableTaskType sets the "task_type" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableTokensCompletion

func (atuo *AgentTaskUpdateOne) SetNillableTokensCompletion(i *int) *AgentTaskUpdateOne

SetNillableTokensCompletion sets the "tokens_completion" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableTokensPrompt

func (atuo *AgentTaskUpdateOne) SetNillableTokensPrompt(i *int) *AgentTaskUpdateOne

SetNillableTokensPrompt sets the "tokens_prompt" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableTokensTotal

func (atuo *AgentTaskUpdateOne) SetNillableTokensTotal(i *int) *AgentTaskUpdateOne

SetNillableTokensTotal sets the "tokens_total" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableToolCallCount

func (atuo *AgentTaskUpdateOne) SetNillableToolCallCount(i *int) *AgentTaskUpdateOne

SetNillableToolCallCount sets the "tool_call_count" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableTraceID

func (atuo *AgentTaskUpdateOne) SetNillableTraceID(s *string) *AgentTaskUpdateOne

SetNillableTraceID sets the "trace_id" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetNillableWorkflowID

func (atuo *AgentTaskUpdateOne) SetNillableWorkflowID(s *string) *AgentTaskUpdateOne

SetNillableWorkflowID sets the "workflow_id" field if the given value is not nil.

func (*AgentTaskUpdateOne) SetOutput

func (atuo *AgentTaskUpdateOne) SetOutput(m map[string]interface{}) *AgentTaskUpdateOne

SetOutput sets the "output" field.

func (*AgentTaskUpdateOne) SetParentSpanID

func (atuo *AgentTaskUpdateOne) SetParentSpanID(s string) *AgentTaskUpdateOne

SetParentSpanID sets the "parent_span_id" field.

func (*AgentTaskUpdateOne) SetRetryCount

func (atuo *AgentTaskUpdateOne) SetRetryCount(i int) *AgentTaskUpdateOne

SetRetryCount sets the "retry_count" field.

func (*AgentTaskUpdateOne) SetSpanID

func (atuo *AgentTaskUpdateOne) SetSpanID(s string) *AgentTaskUpdateOne

SetSpanID sets the "span_id" field.

func (*AgentTaskUpdateOne) SetStatus

func (atuo *AgentTaskUpdateOne) SetStatus(s string) *AgentTaskUpdateOne

SetStatus sets the "status" field.

func (*AgentTaskUpdateOne) SetTaskType

func (atuo *AgentTaskUpdateOne) SetTaskType(s string) *AgentTaskUpdateOne

SetTaskType sets the "task_type" field.

func (*AgentTaskUpdateOne) SetTokensCompletion

func (atuo *AgentTaskUpdateOne) SetTokensCompletion(i int) *AgentTaskUpdateOne

SetTokensCompletion sets the "tokens_completion" field.

func (*AgentTaskUpdateOne) SetTokensPrompt

func (atuo *AgentTaskUpdateOne) SetTokensPrompt(i int) *AgentTaskUpdateOne

SetTokensPrompt sets the "tokens_prompt" field.

func (*AgentTaskUpdateOne) SetTokensTotal

func (atuo *AgentTaskUpdateOne) SetTokensTotal(i int) *AgentTaskUpdateOne

SetTokensTotal sets the "tokens_total" field.

func (*AgentTaskUpdateOne) SetToolCallCount

func (atuo *AgentTaskUpdateOne) SetToolCallCount(i int) *AgentTaskUpdateOne

SetToolCallCount sets the "tool_call_count" field.

func (*AgentTaskUpdateOne) SetTraceID

func (atuo *AgentTaskUpdateOne) SetTraceID(s string) *AgentTaskUpdateOne

SetTraceID sets the "trace_id" field.

func (*AgentTaskUpdateOne) SetUpdatedAt

func (atuo *AgentTaskUpdateOne) SetUpdatedAt(t time.Time) *AgentTaskUpdateOne

SetUpdatedAt sets the "updated_at" field.

func (*AgentTaskUpdateOne) SetWorkflow

func (atuo *AgentTaskUpdateOne) SetWorkflow(w *Workflow) *AgentTaskUpdateOne

SetWorkflow sets the "workflow" edge to the Workflow entity.

func (*AgentTaskUpdateOne) SetWorkflowID

func (atuo *AgentTaskUpdateOne) SetWorkflowID(s string) *AgentTaskUpdateOne

SetWorkflowID sets the "workflow_id" field.

func (*AgentTaskUpdateOne) Where

Where appends a list predicates to the AgentTaskUpdate builder.

type AgentTasks

type AgentTasks []*AgentTask

AgentTasks is a parsable slice of AgentTask.

type AggregateFunc

type AggregateFunc func(*sql.Selector) string

AggregateFunc applies an aggregation step on the group-by traversal/selector.

func As

As is a pseudo aggregation function for renaming another other functions with custom names. For example:

GroupBy(field1, field2).
Aggregate(ent.As(ent.Sum(field1), "sum_field1"), (ent.As(ent.Sum(field2), "sum_field2")).
Scan(ctx, &v)

func Count

func Count() AggregateFunc

Count applies the "count" aggregation function on each group.

func Max

func Max(field string) AggregateFunc

Max applies the "max" aggregation function on the given field of each group.

func Mean

func Mean(field string) AggregateFunc

Mean applies the "mean" aggregation function on the given field of each group.

func Min

func Min(field string) AggregateFunc

Min applies the "min" aggregation function on the given field of each group.

func Sum

func Sum(field string) AggregateFunc

Sum applies the "sum" aggregation function on the given field of each group.

type Client

type Client struct {

	// Schema is the client for creating, migrating and dropping schema.
	Schema *migrate.Schema
	// AgentEvent is the client for interacting with the AgentEvent builders.
	AgentEvent *AgentEventClient
	// AgentHandoff is the client for interacting with the AgentHandoff builders.
	AgentHandoff *AgentHandoffClient
	// AgentTask is the client for interacting with the AgentTask builders.
	AgentTask *AgentTaskClient
	// ToolInvocation is the client for interacting with the ToolInvocation builders.
	ToolInvocation *ToolInvocationClient
	// Workflow is the client for interacting with the Workflow builders.
	Workflow *WorkflowClient
	// contains filtered or unexported fields
}

Client is the client that holds all ent builders.

func FromContext

func FromContext(ctx context.Context) *Client

FromContext returns a Client stored inside a context, or nil if there isn't one.

func NewClient

func NewClient(opts ...Option) *Client

NewClient creates a new client configured with the given options.

func Open

func Open(driverName, dataSourceName string, options ...Option) (*Client, error)

Open opens a database/sql.DB specified by the driver name and the data source name, and returns a new client attached to it. Optional parameters can be added for configuring the client.

func (*Client) BeginTx

func (c *Client) BeginTx(ctx context.Context, opts *sql.TxOptions) (*Tx, error)

BeginTx returns a transactional client with specified options.

func (*Client) Close

func (c *Client) Close() error

Close closes the database connection and prevents new queries from starting.

func (*Client) Debug

func (c *Client) Debug() *Client

Debug returns a new debug-client. It's used to get verbose logging on specific operations.

client.Debug().
	AgentEvent.
	Query().
	Count(ctx)

func (*Client) Intercept

func (c *Client) Intercept(interceptors ...Interceptor)

Intercept adds the query interceptors to all the entity clients. In order to add interceptors to a specific client, call: `client.Node.Intercept(...)`.

func (*Client) Mutate

func (c *Client) Mutate(ctx context.Context, m Mutation) (Value, error)

Mutate implements the ent.Mutator interface.

func (*Client) Tx

func (c *Client) Tx(ctx context.Context) (*Tx, error)

Tx returns a new transactional client. The provided context is used until the transaction is committed or rolled back.

func (*Client) Use

func (c *Client) Use(hooks ...Hook)

Use adds the mutation hooks to all the entity clients. In order to add hooks to a specific client, call: `client.Node.Use(...)`.

type CommitFunc

type CommitFunc func(context.Context, *Tx) error

The CommitFunc type is an adapter to allow the use of ordinary function as a Committer. If f is a function with the appropriate signature, CommitFunc(f) is a Committer that calls f.

func (CommitFunc) Commit

func (f CommitFunc) Commit(ctx context.Context, tx *Tx) error

Commit calls f(ctx, m).

type CommitHook

type CommitHook func(Committer) Committer

CommitHook defines the "commit middleware". A function that gets a Committer and returns a Committer. For example:

hook := func(next ent.Committer) ent.Committer {
	return ent.CommitFunc(func(ctx context.Context, tx *ent.Tx) error {
		// Do some stuff before.
		if err := next.Commit(ctx, tx); err != nil {
			return err
		}
		// Do some stuff after.
		return nil
	})
}

type Committer

type Committer interface {
	Commit(context.Context, *Tx) error
}

Committer is the interface that wraps the Commit method.

type ConstraintError

type ConstraintError struct {
	// contains filtered or unexported fields
}

ConstraintError returns when trying to create/update one or more entities and one or more of their constraints failed. For example, violation of edge or field uniqueness.

func (ConstraintError) Error

func (e ConstraintError) Error() string

Error implements the error interface.

func (*ConstraintError) Unwrap

func (e *ConstraintError) Unwrap() error

Unwrap implements the errors.Wrapper interface.

type Hook

type Hook = ent.Hook

ent aliases to avoid import conflicts in user's code.

type InterceptFunc

type InterceptFunc = ent.InterceptFunc

ent aliases to avoid import conflicts in user's code.

type Interceptor

type Interceptor = ent.Interceptor

ent aliases to avoid import conflicts in user's code.

type MutateFunc

type MutateFunc = ent.MutateFunc

ent aliases to avoid import conflicts in user's code.

type Mutation

type Mutation = ent.Mutation

ent aliases to avoid import conflicts in user's code.

type Mutator

type Mutator = ent.Mutator

ent aliases to avoid import conflicts in user's code.

type NotFoundError

type NotFoundError struct {
	// contains filtered or unexported fields
}

NotFoundError returns when trying to fetch a specific entity and it was not found in the database.

func (*NotFoundError) Error

func (e *NotFoundError) Error() string

Error implements the error interface.

type NotLoadedError

type NotLoadedError struct {
	// contains filtered or unexported fields
}

NotLoadedError returns when trying to get a node that was not loaded by the query.

func (*NotLoadedError) Error

func (e *NotLoadedError) Error() string

Error implements the error interface.

type NotSingularError

type NotSingularError struct {
	// contains filtered or unexported fields
}

NotSingularError returns when trying to fetch a singular entity and more then one was found in the database.

func (*NotSingularError) Error

func (e *NotSingularError) Error() string

Error implements the error interface.

type Op

type Op = ent.Op

ent aliases to avoid import conflicts in user's code.

type Option

type Option func(*config)

Option function to configure the client.

func Debug

func Debug() Option

Debug enables debug logging on the ent.Driver.

func Driver

func Driver(driver dialect.Driver) Option

Driver configures the client driver.

func Log

func Log(fn func(...any)) Option

Log sets the logging function for debug mode.

type OrderFunc

type OrderFunc func(*sql.Selector)

OrderFunc applies an ordering on the sql selector. Deprecated: Use Asc/Desc functions or the package builders instead.

type Policy

type Policy = ent.Policy

ent aliases to avoid import conflicts in user's code.

type Querier

type Querier = ent.Querier

ent aliases to avoid import conflicts in user's code.

type QuerierFunc

type QuerierFunc = ent.QuerierFunc

ent aliases to avoid import conflicts in user's code.

type Query

type Query = ent.Query

ent aliases to avoid import conflicts in user's code.

type QueryContext

type QueryContext = ent.QueryContext

ent aliases to avoid import conflicts in user's code.

type RollbackFunc

type RollbackFunc func(context.Context, *Tx) error

The RollbackFunc type is an adapter to allow the use of ordinary function as a Rollbacker. If f is a function with the appropriate signature, RollbackFunc(f) is a Rollbacker that calls f.

func (RollbackFunc) Rollback

func (f RollbackFunc) Rollback(ctx context.Context, tx *Tx) error

Rollback calls f(ctx, m).

type RollbackHook

type RollbackHook func(Rollbacker) Rollbacker

RollbackHook defines the "rollback middleware". A function that gets a Rollbacker and returns a Rollbacker. For example:

hook := func(next ent.Rollbacker) ent.Rollbacker {
	return ent.RollbackFunc(func(ctx context.Context, tx *ent.Tx) error {
		// Do some stuff before.
		if err := next.Rollback(ctx, tx); err != nil {
			return err
		}
		// Do some stuff after.
		return nil
	})
}

type Rollbacker

type Rollbacker interface {
	Rollback(context.Context, *Tx) error
}

Rollbacker is the interface that wraps the Rollback method.

type ToolInvocation

type ToolInvocation struct {

	// ID of the ent.
	// Unique invocation identifier (UUID)
	ID string `json:"id,omitempty"`
	// Parent task ID
	TaskID string `json:"task_id,omitempty"`
	// Agent that invoked the tool
	AgentID string `json:"agent_id,omitempty"`
	// Name of the tool (e.g., 'web_fetch', 'database_query', 'calculator')
	ToolName string `json:"tool_name,omitempty"`
	// Category of tool: http, database, file, function, external_api
	ToolType string `json:"tool_type,omitempty"`
	// Invocation status: running, success, failed, timeout
	Status string `json:"status,omitempty"`
	// OpenTelemetry trace ID
	TraceID string `json:"trace_id,omitempty"`
	// OpenTelemetry span ID
	SpanID string `json:"span_id,omitempty"`
	// Tool input/arguments
	Input map[string]interface{} `json:"input,omitempty"`
	// Tool output/result
	Output map[string]interface{} `json:"output,omitempty"`
	// Additional metadata
	Metadata map[string]interface{} `json:"metadata,omitempty"`
	// HTTP method if applicable
	HTTPMethod string `json:"http_method,omitempty"`
	// HTTP URL if applicable
	HTTPURL string `json:"http_url,omitempty"`
	// HTTP status code if applicable
	HTTPStatusCode int `json:"http_status_code,omitempty"`
	// Invocation duration in milliseconds
	DurationMs int64 `json:"duration_ms,omitempty"`
	// Size of the request in bytes
	RequestSizeBytes int `json:"request_size_bytes,omitempty"`
	// Size of the response in bytes
	ResponseSizeBytes int `json:"response_size_bytes,omitempty"`
	// Number of retries
	RetryCount int `json:"retry_count,omitempty"`
	// Error type if invocation failed
	ErrorType string `json:"error_type,omitempty"`
	// Error message if invocation failed
	ErrorMessage string `json:"error_message,omitempty"`
	// When the invocation started
	StartedAt time.Time `json:"started_at,omitempty"`
	// When the invocation ended
	EndedAt *time.Time `json:"ended_at,omitempty"`
	// CreatedAt holds the value of the "created_at" field.
	CreatedAt time.Time `json:"created_at,omitempty"`
	// UpdatedAt holds the value of the "updated_at" field.
	UpdatedAt time.Time `json:"updated_at,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the ToolInvocationQuery when eager-loading is set.
	Edges ToolInvocationEdges `json:"edges"`
	// contains filtered or unexported fields
}

ToolInvocation is the model entity for the ToolInvocation schema.

func (*ToolInvocation) QueryTask

func (ti *ToolInvocation) QueryTask() *AgentTaskQuery

QueryTask queries the "task" edge of the ToolInvocation entity.

func (*ToolInvocation) String

func (ti *ToolInvocation) String() string

String implements the fmt.Stringer.

func (*ToolInvocation) Unwrap

func (ti *ToolInvocation) Unwrap() *ToolInvocation

Unwrap unwraps the ToolInvocation entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*ToolInvocation) Update

Update returns a builder for updating this ToolInvocation. Note that you need to call ToolInvocation.Unwrap() before calling this method if this ToolInvocation was returned from a transaction, and the transaction was committed or rolled back.

func (*ToolInvocation) Value

func (ti *ToolInvocation) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the ToolInvocation. This includes values selected through modifiers, order, etc.

type ToolInvocationClient

type ToolInvocationClient struct {
	// contains filtered or unexported fields
}

ToolInvocationClient is a client for the ToolInvocation schema.

func NewToolInvocationClient

func NewToolInvocationClient(c config) *ToolInvocationClient

NewToolInvocationClient returns a client for the ToolInvocation from the given config.

func (*ToolInvocationClient) Create

Create returns a builder for creating a ToolInvocation entity.

func (*ToolInvocationClient) CreateBulk

CreateBulk returns a builder for creating a bulk of ToolInvocation entities.

func (*ToolInvocationClient) Delete

Delete returns a delete builder for ToolInvocation.

func (*ToolInvocationClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*ToolInvocationClient) DeleteOneID

DeleteOneID returns a builder for deleting the given entity by its id.

func (*ToolInvocationClient) Get

Get returns a ToolInvocation entity by its id.

func (*ToolInvocationClient) GetX

GetX is like Get, but panics if an error occurs.

func (*ToolInvocationClient) Hooks

func (c *ToolInvocationClient) Hooks() []Hook

Hooks returns the client hooks.

func (*ToolInvocationClient) Intercept

func (c *ToolInvocationClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `toolinvocation.Intercept(f(g(h())))`.

func (*ToolInvocationClient) Interceptors

func (c *ToolInvocationClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*ToolInvocationClient) MapCreateBulk

func (c *ToolInvocationClient) MapCreateBulk(slice any, setFunc func(*ToolInvocationCreate, int)) *ToolInvocationCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*ToolInvocationClient) Query

Query returns a query builder for ToolInvocation.

func (*ToolInvocationClient) QueryTask

QueryTask queries the task edge of a ToolInvocation.

func (*ToolInvocationClient) Update

Update returns an update builder for ToolInvocation.

func (*ToolInvocationClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*ToolInvocationClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*ToolInvocationClient) Use

func (c *ToolInvocationClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `toolinvocation.Hooks(f(g(h())))`.

type ToolInvocationCreate

type ToolInvocationCreate struct {
	// contains filtered or unexported fields
}

ToolInvocationCreate is the builder for creating a ToolInvocation entity.

func (*ToolInvocationCreate) Exec

func (tic *ToolInvocationCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*ToolInvocationCreate) ExecX

func (tic *ToolInvocationCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ToolInvocationCreate) Mutation

Mutation returns the ToolInvocationMutation object of the builder.

func (*ToolInvocationCreate) Save

Save creates the ToolInvocation in the database.

func (*ToolInvocationCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*ToolInvocationCreate) SetAgentID

func (tic *ToolInvocationCreate) SetAgentID(s string) *ToolInvocationCreate

SetAgentID sets the "agent_id" field.

func (*ToolInvocationCreate) SetCreatedAt

func (tic *ToolInvocationCreate) SetCreatedAt(t time.Time) *ToolInvocationCreate

SetCreatedAt sets the "created_at" field.

func (*ToolInvocationCreate) SetDurationMs

func (tic *ToolInvocationCreate) SetDurationMs(i int64) *ToolInvocationCreate

SetDurationMs sets the "duration_ms" field.

func (*ToolInvocationCreate) SetEndedAt

func (tic *ToolInvocationCreate) SetEndedAt(t time.Time) *ToolInvocationCreate

SetEndedAt sets the "ended_at" field.

func (*ToolInvocationCreate) SetErrorMessage

func (tic *ToolInvocationCreate) SetErrorMessage(s string) *ToolInvocationCreate

SetErrorMessage sets the "error_message" field.

func (*ToolInvocationCreate) SetErrorType

func (tic *ToolInvocationCreate) SetErrorType(s string) *ToolInvocationCreate

SetErrorType sets the "error_type" field.

func (*ToolInvocationCreate) SetHTTPMethod

func (tic *ToolInvocationCreate) SetHTTPMethod(s string) *ToolInvocationCreate

SetHTTPMethod sets the "http_method" field.

func (*ToolInvocationCreate) SetHTTPStatusCode

func (tic *ToolInvocationCreate) SetHTTPStatusCode(i int) *ToolInvocationCreate

SetHTTPStatusCode sets the "http_status_code" field.

func (*ToolInvocationCreate) SetHTTPURL

func (tic *ToolInvocationCreate) SetHTTPURL(s string) *ToolInvocationCreate

SetHTTPURL sets the "http_url" field.

func (*ToolInvocationCreate) SetID

SetID sets the "id" field.

func (*ToolInvocationCreate) SetInput

func (tic *ToolInvocationCreate) SetInput(m map[string]interface{}) *ToolInvocationCreate

SetInput sets the "input" field.

func (*ToolInvocationCreate) SetMetadata

func (tic *ToolInvocationCreate) SetMetadata(m map[string]interface{}) *ToolInvocationCreate

SetMetadata sets the "metadata" field.

func (*ToolInvocationCreate) SetNillableCreatedAt

func (tic *ToolInvocationCreate) SetNillableCreatedAt(t *time.Time) *ToolInvocationCreate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*ToolInvocationCreate) SetNillableDurationMs

func (tic *ToolInvocationCreate) SetNillableDurationMs(i *int64) *ToolInvocationCreate

SetNillableDurationMs sets the "duration_ms" field if the given value is not nil.

func (*ToolInvocationCreate) SetNillableEndedAt

func (tic *ToolInvocationCreate) SetNillableEndedAt(t *time.Time) *ToolInvocationCreate

SetNillableEndedAt sets the "ended_at" field if the given value is not nil.

func (*ToolInvocationCreate) SetNillableErrorMessage

func (tic *ToolInvocationCreate) SetNillableErrorMessage(s *string) *ToolInvocationCreate

SetNillableErrorMessage sets the "error_message" field if the given value is not nil.

func (*ToolInvocationCreate) SetNillableErrorType

func (tic *ToolInvocationCreate) SetNillableErrorType(s *string) *ToolInvocationCreate

SetNillableErrorType sets the "error_type" field if the given value is not nil.

func (*ToolInvocationCreate) SetNillableHTTPMethod

func (tic *ToolInvocationCreate) SetNillableHTTPMethod(s *string) *ToolInvocationCreate

SetNillableHTTPMethod sets the "http_method" field if the given value is not nil.

func (*ToolInvocationCreate) SetNillableHTTPStatusCode

func (tic *ToolInvocationCreate) SetNillableHTTPStatusCode(i *int) *ToolInvocationCreate

SetNillableHTTPStatusCode sets the "http_status_code" field if the given value is not nil.

func (*ToolInvocationCreate) SetNillableHTTPURL

func (tic *ToolInvocationCreate) SetNillableHTTPURL(s *string) *ToolInvocationCreate

SetNillableHTTPURL sets the "http_url" field if the given value is not nil.

func (*ToolInvocationCreate) SetNillableRequestSizeBytes

func (tic *ToolInvocationCreate) SetNillableRequestSizeBytes(i *int) *ToolInvocationCreate

SetNillableRequestSizeBytes sets the "request_size_bytes" field if the given value is not nil.

func (*ToolInvocationCreate) SetNillableResponseSizeBytes

func (tic *ToolInvocationCreate) SetNillableResponseSizeBytes(i *int) *ToolInvocationCreate

SetNillableResponseSizeBytes sets the "response_size_bytes" field if the given value is not nil.

func (*ToolInvocationCreate) SetNillableRetryCount

func (tic *ToolInvocationCreate) SetNillableRetryCount(i *int) *ToolInvocationCreate

SetNillableRetryCount sets the "retry_count" field if the given value is not nil.

func (*ToolInvocationCreate) SetNillableSpanID

func (tic *ToolInvocationCreate) SetNillableSpanID(s *string) *ToolInvocationCreate

SetNillableSpanID sets the "span_id" field if the given value is not nil.

func (*ToolInvocationCreate) SetNillableStartedAt

func (tic *ToolInvocationCreate) SetNillableStartedAt(t *time.Time) *ToolInvocationCreate

SetNillableStartedAt sets the "started_at" field if the given value is not nil.

func (*ToolInvocationCreate) SetNillableStatus

func (tic *ToolInvocationCreate) SetNillableStatus(s *string) *ToolInvocationCreate

SetNillableStatus sets the "status" field if the given value is not nil.

func (*ToolInvocationCreate) SetNillableTaskID

func (tic *ToolInvocationCreate) SetNillableTaskID(s *string) *ToolInvocationCreate

SetNillableTaskID sets the "task_id" field if the given value is not nil.

func (*ToolInvocationCreate) SetNillableToolType

func (tic *ToolInvocationCreate) SetNillableToolType(s *string) *ToolInvocationCreate

SetNillableToolType sets the "tool_type" field if the given value is not nil.

func (*ToolInvocationCreate) SetNillableTraceID

func (tic *ToolInvocationCreate) SetNillableTraceID(s *string) *ToolInvocationCreate

SetNillableTraceID sets the "trace_id" field if the given value is not nil.

func (*ToolInvocationCreate) SetNillableUpdatedAt

func (tic *ToolInvocationCreate) SetNillableUpdatedAt(t *time.Time) *ToolInvocationCreate

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*ToolInvocationCreate) SetOutput

func (tic *ToolInvocationCreate) SetOutput(m map[string]interface{}) *ToolInvocationCreate

SetOutput sets the "output" field.

func (*ToolInvocationCreate) SetRequestSizeBytes

func (tic *ToolInvocationCreate) SetRequestSizeBytes(i int) *ToolInvocationCreate

SetRequestSizeBytes sets the "request_size_bytes" field.

func (*ToolInvocationCreate) SetResponseSizeBytes

func (tic *ToolInvocationCreate) SetResponseSizeBytes(i int) *ToolInvocationCreate

SetResponseSizeBytes sets the "response_size_bytes" field.

func (*ToolInvocationCreate) SetRetryCount

func (tic *ToolInvocationCreate) SetRetryCount(i int) *ToolInvocationCreate

SetRetryCount sets the "retry_count" field.

func (*ToolInvocationCreate) SetSpanID

SetSpanID sets the "span_id" field.

func (*ToolInvocationCreate) SetStartedAt

func (tic *ToolInvocationCreate) SetStartedAt(t time.Time) *ToolInvocationCreate

SetStartedAt sets the "started_at" field.

func (*ToolInvocationCreate) SetStatus

SetStatus sets the "status" field.

func (*ToolInvocationCreate) SetTask

SetTask sets the "task" edge to the AgentTask entity.

func (*ToolInvocationCreate) SetTaskID

SetTaskID sets the "task_id" field.

func (*ToolInvocationCreate) SetToolName

func (tic *ToolInvocationCreate) SetToolName(s string) *ToolInvocationCreate

SetToolName sets the "tool_name" field.

func (*ToolInvocationCreate) SetToolType

func (tic *ToolInvocationCreate) SetToolType(s string) *ToolInvocationCreate

SetToolType sets the "tool_type" field.

func (*ToolInvocationCreate) SetTraceID

func (tic *ToolInvocationCreate) SetTraceID(s string) *ToolInvocationCreate

SetTraceID sets the "trace_id" field.

func (*ToolInvocationCreate) SetUpdatedAt

func (tic *ToolInvocationCreate) SetUpdatedAt(t time.Time) *ToolInvocationCreate

SetUpdatedAt sets the "updated_at" field.

type ToolInvocationCreateBulk

type ToolInvocationCreateBulk struct {
	// contains filtered or unexported fields
}

ToolInvocationCreateBulk is the builder for creating many ToolInvocation entities in bulk.

func (*ToolInvocationCreateBulk) Exec

Exec executes the query.

func (*ToolInvocationCreateBulk) ExecX

func (ticb *ToolInvocationCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ToolInvocationCreateBulk) Save

Save creates the ToolInvocation entities in the database.

func (*ToolInvocationCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type ToolInvocationDelete

type ToolInvocationDelete struct {
	// contains filtered or unexported fields
}

ToolInvocationDelete is the builder for deleting a ToolInvocation entity.

func (*ToolInvocationDelete) Exec

func (tid *ToolInvocationDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*ToolInvocationDelete) ExecX

func (tid *ToolInvocationDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*ToolInvocationDelete) Where

Where appends a list predicates to the ToolInvocationDelete builder.

type ToolInvocationDeleteOne

type ToolInvocationDeleteOne struct {
	// contains filtered or unexported fields
}

ToolInvocationDeleteOne is the builder for deleting a single ToolInvocation entity.

func (*ToolInvocationDeleteOne) Exec

func (tido *ToolInvocationDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*ToolInvocationDeleteOne) ExecX

func (tido *ToolInvocationDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ToolInvocationDeleteOne) Where

Where appends a list predicates to the ToolInvocationDelete builder.

type ToolInvocationEdges

type ToolInvocationEdges struct {
	// Task holds the value of the task edge.
	Task *AgentTask `json:"task,omitempty"`
	// contains filtered or unexported fields
}

ToolInvocationEdges holds the relations/edges for other nodes in the graph.

func (ToolInvocationEdges) TaskOrErr

func (e ToolInvocationEdges) TaskOrErr() (*AgentTask, error)

TaskOrErr returns the Task value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

type ToolInvocationGroupBy

type ToolInvocationGroupBy struct {
	// contains filtered or unexported fields
}

ToolInvocationGroupBy is the group-by builder for ToolInvocation entities.

func (*ToolInvocationGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*ToolInvocationGroupBy) Bool

func (s *ToolInvocationGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ToolInvocationGroupBy) BoolX

func (s *ToolInvocationGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ToolInvocationGroupBy) Bools

func (s *ToolInvocationGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ToolInvocationGroupBy) BoolsX

func (s *ToolInvocationGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ToolInvocationGroupBy) Float64

func (s *ToolInvocationGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ToolInvocationGroupBy) Float64X

func (s *ToolInvocationGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ToolInvocationGroupBy) Float64s

func (s *ToolInvocationGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ToolInvocationGroupBy) Float64sX

func (s *ToolInvocationGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ToolInvocationGroupBy) Int

func (s *ToolInvocationGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ToolInvocationGroupBy) IntX

func (s *ToolInvocationGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ToolInvocationGroupBy) Ints

func (s *ToolInvocationGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ToolInvocationGroupBy) IntsX

func (s *ToolInvocationGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ToolInvocationGroupBy) Scan

func (tigb *ToolInvocationGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*ToolInvocationGroupBy) ScanX

func (s *ToolInvocationGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*ToolInvocationGroupBy) String

func (s *ToolInvocationGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ToolInvocationGroupBy) StringX

func (s *ToolInvocationGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ToolInvocationGroupBy) Strings

func (s *ToolInvocationGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ToolInvocationGroupBy) StringsX

func (s *ToolInvocationGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ToolInvocationMutation

type ToolInvocationMutation struct {
	// contains filtered or unexported fields
}

ToolInvocationMutation represents an operation that mutates the ToolInvocation nodes in the graph.

func (*ToolInvocationMutation) AddDurationMs

func (m *ToolInvocationMutation) AddDurationMs(i int64)

AddDurationMs adds i to the "duration_ms" field.

func (*ToolInvocationMutation) AddField

func (m *ToolInvocationMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ToolInvocationMutation) AddHTTPStatusCode

func (m *ToolInvocationMutation) AddHTTPStatusCode(i int)

AddHTTPStatusCode adds i to the "http_status_code" field.

func (*ToolInvocationMutation) AddRequestSizeBytes

func (m *ToolInvocationMutation) AddRequestSizeBytes(i int)

AddRequestSizeBytes adds i to the "request_size_bytes" field.

func (*ToolInvocationMutation) AddResponseSizeBytes

func (m *ToolInvocationMutation) AddResponseSizeBytes(i int)

AddResponseSizeBytes adds i to the "response_size_bytes" field.

func (*ToolInvocationMutation) AddRetryCount

func (m *ToolInvocationMutation) AddRetryCount(i int)

AddRetryCount adds i to the "retry_count" field.

func (*ToolInvocationMutation) AddedDurationMs

func (m *ToolInvocationMutation) AddedDurationMs() (r int64, exists bool)

AddedDurationMs returns the value that was added to the "duration_ms" field in this mutation.

func (*ToolInvocationMutation) AddedEdges

func (m *ToolInvocationMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*ToolInvocationMutation) AddedField

func (m *ToolInvocationMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ToolInvocationMutation) AddedFields

func (m *ToolInvocationMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*ToolInvocationMutation) AddedHTTPStatusCode

func (m *ToolInvocationMutation) AddedHTTPStatusCode() (r int, exists bool)

AddedHTTPStatusCode returns the value that was added to the "http_status_code" field in this mutation.

func (*ToolInvocationMutation) AddedIDs

func (m *ToolInvocationMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*ToolInvocationMutation) AddedRequestSizeBytes

func (m *ToolInvocationMutation) AddedRequestSizeBytes() (r int, exists bool)

AddedRequestSizeBytes returns the value that was added to the "request_size_bytes" field in this mutation.

func (*ToolInvocationMutation) AddedResponseSizeBytes

func (m *ToolInvocationMutation) AddedResponseSizeBytes() (r int, exists bool)

AddedResponseSizeBytes returns the value that was added to the "response_size_bytes" field in this mutation.

func (*ToolInvocationMutation) AddedRetryCount

func (m *ToolInvocationMutation) AddedRetryCount() (r int, exists bool)

AddedRetryCount returns the value that was added to the "retry_count" field in this mutation.

func (*ToolInvocationMutation) AgentID

func (m *ToolInvocationMutation) AgentID() (r string, exists bool)

AgentID returns the value of the "agent_id" field in the mutation.

func (*ToolInvocationMutation) ClearDurationMs

func (m *ToolInvocationMutation) ClearDurationMs()

ClearDurationMs clears the value of the "duration_ms" field.

func (*ToolInvocationMutation) ClearEdge

func (m *ToolInvocationMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*ToolInvocationMutation) ClearEndedAt

func (m *ToolInvocationMutation) ClearEndedAt()

ClearEndedAt clears the value of the "ended_at" field.

func (*ToolInvocationMutation) ClearErrorMessage

func (m *ToolInvocationMutation) ClearErrorMessage()

ClearErrorMessage clears the value of the "error_message" field.

func (*ToolInvocationMutation) ClearErrorType

func (m *ToolInvocationMutation) ClearErrorType()

ClearErrorType clears the value of the "error_type" field.

func (*ToolInvocationMutation) ClearField

func (m *ToolInvocationMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*ToolInvocationMutation) ClearHTTPMethod

func (m *ToolInvocationMutation) ClearHTTPMethod()

ClearHTTPMethod clears the value of the "http_method" field.

func (*ToolInvocationMutation) ClearHTTPStatusCode

func (m *ToolInvocationMutation) ClearHTTPStatusCode()

ClearHTTPStatusCode clears the value of the "http_status_code" field.

func (*ToolInvocationMutation) ClearHTTPURL

func (m *ToolInvocationMutation) ClearHTTPURL()

ClearHTTPURL clears the value of the "http_url" field.

func (*ToolInvocationMutation) ClearInput

func (m *ToolInvocationMutation) ClearInput()

ClearInput clears the value of the "input" field.

func (*ToolInvocationMutation) ClearMetadata

func (m *ToolInvocationMutation) ClearMetadata()

ClearMetadata clears the value of the "metadata" field.

func (*ToolInvocationMutation) ClearOutput

func (m *ToolInvocationMutation) ClearOutput()

ClearOutput clears the value of the "output" field.

func (*ToolInvocationMutation) ClearSpanID

func (m *ToolInvocationMutation) ClearSpanID()

ClearSpanID clears the value of the "span_id" field.

func (*ToolInvocationMutation) ClearTask

func (m *ToolInvocationMutation) ClearTask()

ClearTask clears the "task" edge to the AgentTask entity.

func (*ToolInvocationMutation) ClearTaskID

func (m *ToolInvocationMutation) ClearTaskID()

ClearTaskID clears the value of the "task_id" field.

func (*ToolInvocationMutation) ClearToolType

func (m *ToolInvocationMutation) ClearToolType()

ClearToolType clears the value of the "tool_type" field.

func (*ToolInvocationMutation) ClearTraceID

func (m *ToolInvocationMutation) ClearTraceID()

ClearTraceID clears the value of the "trace_id" field.

func (*ToolInvocationMutation) ClearedEdges

func (m *ToolInvocationMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*ToolInvocationMutation) ClearedFields

func (m *ToolInvocationMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (ToolInvocationMutation) Client

func (m ToolInvocationMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*ToolInvocationMutation) CreatedAt

func (m *ToolInvocationMutation) CreatedAt() (r time.Time, exists bool)

CreatedAt returns the value of the "created_at" field in the mutation.

func (*ToolInvocationMutation) DurationMs

func (m *ToolInvocationMutation) DurationMs() (r int64, exists bool)

DurationMs returns the value of the "duration_ms" field in the mutation.

func (*ToolInvocationMutation) DurationMsCleared

func (m *ToolInvocationMutation) DurationMsCleared() bool

DurationMsCleared returns if the "duration_ms" field was cleared in this mutation.

func (*ToolInvocationMutation) EdgeCleared

func (m *ToolInvocationMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*ToolInvocationMutation) EndedAt

func (m *ToolInvocationMutation) EndedAt() (r time.Time, exists bool)

EndedAt returns the value of the "ended_at" field in the mutation.

func (*ToolInvocationMutation) EndedAtCleared

func (m *ToolInvocationMutation) EndedAtCleared() bool

EndedAtCleared returns if the "ended_at" field was cleared in this mutation.

func (*ToolInvocationMutation) ErrorMessage

func (m *ToolInvocationMutation) ErrorMessage() (r string, exists bool)

ErrorMessage returns the value of the "error_message" field in the mutation.

func (*ToolInvocationMutation) ErrorMessageCleared

func (m *ToolInvocationMutation) ErrorMessageCleared() bool

ErrorMessageCleared returns if the "error_message" field was cleared in this mutation.

func (*ToolInvocationMutation) ErrorType

func (m *ToolInvocationMutation) ErrorType() (r string, exists bool)

ErrorType returns the value of the "error_type" field in the mutation.

func (*ToolInvocationMutation) ErrorTypeCleared

func (m *ToolInvocationMutation) ErrorTypeCleared() bool

ErrorTypeCleared returns if the "error_type" field was cleared in this mutation.

func (*ToolInvocationMutation) Field

func (m *ToolInvocationMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ToolInvocationMutation) FieldCleared

func (m *ToolInvocationMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*ToolInvocationMutation) Fields

func (m *ToolInvocationMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*ToolInvocationMutation) HTTPMethod

func (m *ToolInvocationMutation) HTTPMethod() (r string, exists bool)

HTTPMethod returns the value of the "http_method" field in the mutation.

func (*ToolInvocationMutation) HTTPMethodCleared

func (m *ToolInvocationMutation) HTTPMethodCleared() bool

HTTPMethodCleared returns if the "http_method" field was cleared in this mutation.

func (*ToolInvocationMutation) HTTPStatusCode

func (m *ToolInvocationMutation) HTTPStatusCode() (r int, exists bool)

HTTPStatusCode returns the value of the "http_status_code" field in the mutation.

func (*ToolInvocationMutation) HTTPStatusCodeCleared

func (m *ToolInvocationMutation) HTTPStatusCodeCleared() bool

HTTPStatusCodeCleared returns if the "http_status_code" field was cleared in this mutation.

func (*ToolInvocationMutation) HTTPURL

func (m *ToolInvocationMutation) HTTPURL() (r string, exists bool)

HTTPURL returns the value of the "http_url" field in the mutation.

func (*ToolInvocationMutation) HTTPURLCleared

func (m *ToolInvocationMutation) HTTPURLCleared() bool

HTTPURLCleared returns if the "http_url" field was cleared in this mutation.

func (*ToolInvocationMutation) ID

func (m *ToolInvocationMutation) ID() (id string, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*ToolInvocationMutation) IDs

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*ToolInvocationMutation) Input

func (m *ToolInvocationMutation) Input() (r map[string]interface{}, exists bool)

Input returns the value of the "input" field in the mutation.

func (*ToolInvocationMutation) InputCleared

func (m *ToolInvocationMutation) InputCleared() bool

InputCleared returns if the "input" field was cleared in this mutation.

func (*ToolInvocationMutation) Metadata

func (m *ToolInvocationMutation) Metadata() (r map[string]interface{}, exists bool)

Metadata returns the value of the "metadata" field in the mutation.

func (*ToolInvocationMutation) MetadataCleared

func (m *ToolInvocationMutation) MetadataCleared() bool

MetadataCleared returns if the "metadata" field was cleared in this mutation.

func (*ToolInvocationMutation) OldAgentID

func (m *ToolInvocationMutation) OldAgentID(ctx context.Context) (v string, err error)

OldAgentID returns the old "agent_id" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldCreatedAt

func (m *ToolInvocationMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)

OldCreatedAt returns the old "created_at" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldDurationMs

func (m *ToolInvocationMutation) OldDurationMs(ctx context.Context) (v int64, err error)

OldDurationMs returns the old "duration_ms" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldEndedAt

func (m *ToolInvocationMutation) OldEndedAt(ctx context.Context) (v *time.Time, err error)

OldEndedAt returns the old "ended_at" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldErrorMessage

func (m *ToolInvocationMutation) OldErrorMessage(ctx context.Context) (v string, err error)

OldErrorMessage returns the old "error_message" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldErrorType

func (m *ToolInvocationMutation) OldErrorType(ctx context.Context) (v string, err error)

OldErrorType returns the old "error_type" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldField

func (m *ToolInvocationMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*ToolInvocationMutation) OldHTTPMethod

func (m *ToolInvocationMutation) OldHTTPMethod(ctx context.Context) (v string, err error)

OldHTTPMethod returns the old "http_method" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldHTTPStatusCode

func (m *ToolInvocationMutation) OldHTTPStatusCode(ctx context.Context) (v int, err error)

OldHTTPStatusCode returns the old "http_status_code" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldHTTPURL

func (m *ToolInvocationMutation) OldHTTPURL(ctx context.Context) (v string, err error)

OldHTTPURL returns the old "http_url" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldInput

func (m *ToolInvocationMutation) OldInput(ctx context.Context) (v map[string]interface{}, err error)

OldInput returns the old "input" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldMetadata

func (m *ToolInvocationMutation) OldMetadata(ctx context.Context) (v map[string]interface{}, err error)

OldMetadata returns the old "metadata" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldOutput

func (m *ToolInvocationMutation) OldOutput(ctx context.Context) (v map[string]interface{}, err error)

OldOutput returns the old "output" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldRequestSizeBytes

func (m *ToolInvocationMutation) OldRequestSizeBytes(ctx context.Context) (v int, err error)

OldRequestSizeBytes returns the old "request_size_bytes" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldResponseSizeBytes

func (m *ToolInvocationMutation) OldResponseSizeBytes(ctx context.Context) (v int, err error)

OldResponseSizeBytes returns the old "response_size_bytes" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldRetryCount

func (m *ToolInvocationMutation) OldRetryCount(ctx context.Context) (v int, err error)

OldRetryCount returns the old "retry_count" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldSpanID

func (m *ToolInvocationMutation) OldSpanID(ctx context.Context) (v string, err error)

OldSpanID returns the old "span_id" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldStartedAt

func (m *ToolInvocationMutation) OldStartedAt(ctx context.Context) (v time.Time, err error)

OldStartedAt returns the old "started_at" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldStatus

func (m *ToolInvocationMutation) OldStatus(ctx context.Context) (v string, err error)

OldStatus returns the old "status" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldTaskID

func (m *ToolInvocationMutation) OldTaskID(ctx context.Context) (v string, err error)

OldTaskID returns the old "task_id" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldToolName

func (m *ToolInvocationMutation) OldToolName(ctx context.Context) (v string, err error)

OldToolName returns the old "tool_name" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldToolType

func (m *ToolInvocationMutation) OldToolType(ctx context.Context) (v string, err error)

OldToolType returns the old "tool_type" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldTraceID

func (m *ToolInvocationMutation) OldTraceID(ctx context.Context) (v string, err error)

OldTraceID returns the old "trace_id" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) OldUpdatedAt

func (m *ToolInvocationMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)

OldUpdatedAt returns the old "updated_at" field's value of the ToolInvocation entity. If the ToolInvocation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ToolInvocationMutation) Op

func (m *ToolInvocationMutation) Op() Op

Op returns the operation name.

func (*ToolInvocationMutation) Output

func (m *ToolInvocationMutation) Output() (r map[string]interface{}, exists bool)

Output returns the value of the "output" field in the mutation.

func (*ToolInvocationMutation) OutputCleared

func (m *ToolInvocationMutation) OutputCleared() bool

OutputCleared returns if the "output" field was cleared in this mutation.

func (*ToolInvocationMutation) RemovedEdges

func (m *ToolInvocationMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*ToolInvocationMutation) RemovedIDs

func (m *ToolInvocationMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*ToolInvocationMutation) RequestSizeBytes

func (m *ToolInvocationMutation) RequestSizeBytes() (r int, exists bool)

RequestSizeBytes returns the value of the "request_size_bytes" field in the mutation.

func (*ToolInvocationMutation) ResetAgentID

func (m *ToolInvocationMutation) ResetAgentID()

ResetAgentID resets all changes to the "agent_id" field.

func (*ToolInvocationMutation) ResetCreatedAt

func (m *ToolInvocationMutation) ResetCreatedAt()

ResetCreatedAt resets all changes to the "created_at" field.

func (*ToolInvocationMutation) ResetDurationMs

func (m *ToolInvocationMutation) ResetDurationMs()

ResetDurationMs resets all changes to the "duration_ms" field.

func (*ToolInvocationMutation) ResetEdge

func (m *ToolInvocationMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*ToolInvocationMutation) ResetEndedAt

func (m *ToolInvocationMutation) ResetEndedAt()

ResetEndedAt resets all changes to the "ended_at" field.

func (*ToolInvocationMutation) ResetErrorMessage

func (m *ToolInvocationMutation) ResetErrorMessage()

ResetErrorMessage resets all changes to the "error_message" field.

func (*ToolInvocationMutation) ResetErrorType

func (m *ToolInvocationMutation) ResetErrorType()

ResetErrorType resets all changes to the "error_type" field.

func (*ToolInvocationMutation) ResetField

func (m *ToolInvocationMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*ToolInvocationMutation) ResetHTTPMethod

func (m *ToolInvocationMutation) ResetHTTPMethod()

ResetHTTPMethod resets all changes to the "http_method" field.

func (*ToolInvocationMutation) ResetHTTPStatusCode

func (m *ToolInvocationMutation) ResetHTTPStatusCode()

ResetHTTPStatusCode resets all changes to the "http_status_code" field.

func (*ToolInvocationMutation) ResetHTTPURL

func (m *ToolInvocationMutation) ResetHTTPURL()

ResetHTTPURL resets all changes to the "http_url" field.

func (*ToolInvocationMutation) ResetInput

func (m *ToolInvocationMutation) ResetInput()

ResetInput resets all changes to the "input" field.

func (*ToolInvocationMutation) ResetMetadata

func (m *ToolInvocationMutation) ResetMetadata()

ResetMetadata resets all changes to the "metadata" field.

func (*ToolInvocationMutation) ResetOutput

func (m *ToolInvocationMutation) ResetOutput()

ResetOutput resets all changes to the "output" field.

func (*ToolInvocationMutation) ResetRequestSizeBytes

func (m *ToolInvocationMutation) ResetRequestSizeBytes()

ResetRequestSizeBytes resets all changes to the "request_size_bytes" field.

func (*ToolInvocationMutation) ResetResponseSizeBytes

func (m *ToolInvocationMutation) ResetResponseSizeBytes()

ResetResponseSizeBytes resets all changes to the "response_size_bytes" field.

func (*ToolInvocationMutation) ResetRetryCount

func (m *ToolInvocationMutation) ResetRetryCount()

ResetRetryCount resets all changes to the "retry_count" field.

func (*ToolInvocationMutation) ResetSpanID

func (m *ToolInvocationMutation) ResetSpanID()

ResetSpanID resets all changes to the "span_id" field.

func (*ToolInvocationMutation) ResetStartedAt

func (m *ToolInvocationMutation) ResetStartedAt()

ResetStartedAt resets all changes to the "started_at" field.

func (*ToolInvocationMutation) ResetStatus

func (m *ToolInvocationMutation) ResetStatus()

ResetStatus resets all changes to the "status" field.

func (*ToolInvocationMutation) ResetTask

func (m *ToolInvocationMutation) ResetTask()

ResetTask resets all changes to the "task" edge.

func (*ToolInvocationMutation) ResetTaskID

func (m *ToolInvocationMutation) ResetTaskID()

ResetTaskID resets all changes to the "task_id" field.

func (*ToolInvocationMutation) ResetToolName

func (m *ToolInvocationMutation) ResetToolName()

ResetToolName resets all changes to the "tool_name" field.

func (*ToolInvocationMutation) ResetToolType

func (m *ToolInvocationMutation) ResetToolType()

ResetToolType resets all changes to the "tool_type" field.

func (*ToolInvocationMutation) ResetTraceID

func (m *ToolInvocationMutation) ResetTraceID()

ResetTraceID resets all changes to the "trace_id" field.

func (*ToolInvocationMutation) ResetUpdatedAt

func (m *ToolInvocationMutation) ResetUpdatedAt()

ResetUpdatedAt resets all changes to the "updated_at" field.

func (*ToolInvocationMutation) ResponseSizeBytes

func (m *ToolInvocationMutation) ResponseSizeBytes() (r int, exists bool)

ResponseSizeBytes returns the value of the "response_size_bytes" field in the mutation.

func (*ToolInvocationMutation) RetryCount

func (m *ToolInvocationMutation) RetryCount() (r int, exists bool)

RetryCount returns the value of the "retry_count" field in the mutation.

func (*ToolInvocationMutation) SetAgentID

func (m *ToolInvocationMutation) SetAgentID(s string)

SetAgentID sets the "agent_id" field.

func (*ToolInvocationMutation) SetCreatedAt

func (m *ToolInvocationMutation) SetCreatedAt(t time.Time)

SetCreatedAt sets the "created_at" field.

func (*ToolInvocationMutation) SetDurationMs

func (m *ToolInvocationMutation) SetDurationMs(i int64)

SetDurationMs sets the "duration_ms" field.

func (*ToolInvocationMutation) SetEndedAt

func (m *ToolInvocationMutation) SetEndedAt(t time.Time)

SetEndedAt sets the "ended_at" field.

func (*ToolInvocationMutation) SetErrorMessage

func (m *ToolInvocationMutation) SetErrorMessage(s string)

SetErrorMessage sets the "error_message" field.

func (*ToolInvocationMutation) SetErrorType

func (m *ToolInvocationMutation) SetErrorType(s string)

SetErrorType sets the "error_type" field.

func (*ToolInvocationMutation) SetField

func (m *ToolInvocationMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ToolInvocationMutation) SetHTTPMethod

func (m *ToolInvocationMutation) SetHTTPMethod(s string)

SetHTTPMethod sets the "http_method" field.

func (*ToolInvocationMutation) SetHTTPStatusCode

func (m *ToolInvocationMutation) SetHTTPStatusCode(i int)

SetHTTPStatusCode sets the "http_status_code" field.

func (*ToolInvocationMutation) SetHTTPURL

func (m *ToolInvocationMutation) SetHTTPURL(s string)

SetHTTPURL sets the "http_url" field.

func (*ToolInvocationMutation) SetID

func (m *ToolInvocationMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of ToolInvocation entities.

func (*ToolInvocationMutation) SetInput

func (m *ToolInvocationMutation) SetInput(value map[string]interface{})

SetInput sets the "input" field.

func (*ToolInvocationMutation) SetMetadata

func (m *ToolInvocationMutation) SetMetadata(value map[string]interface{})

SetMetadata sets the "metadata" field.

func (*ToolInvocationMutation) SetOp

func (m *ToolInvocationMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*ToolInvocationMutation) SetOutput

func (m *ToolInvocationMutation) SetOutput(value map[string]interface{})

SetOutput sets the "output" field.

func (*ToolInvocationMutation) SetRequestSizeBytes

func (m *ToolInvocationMutation) SetRequestSizeBytes(i int)

SetRequestSizeBytes sets the "request_size_bytes" field.

func (*ToolInvocationMutation) SetResponseSizeBytes

func (m *ToolInvocationMutation) SetResponseSizeBytes(i int)

SetResponseSizeBytes sets the "response_size_bytes" field.

func (*ToolInvocationMutation) SetRetryCount

func (m *ToolInvocationMutation) SetRetryCount(i int)

SetRetryCount sets the "retry_count" field.

func (*ToolInvocationMutation) SetSpanID

func (m *ToolInvocationMutation) SetSpanID(s string)

SetSpanID sets the "span_id" field.

func (*ToolInvocationMutation) SetStartedAt

func (m *ToolInvocationMutation) SetStartedAt(t time.Time)

SetStartedAt sets the "started_at" field.

func (*ToolInvocationMutation) SetStatus

func (m *ToolInvocationMutation) SetStatus(s string)

SetStatus sets the "status" field.

func (*ToolInvocationMutation) SetTaskID

func (m *ToolInvocationMutation) SetTaskID(s string)

SetTaskID sets the "task_id" field.

func (*ToolInvocationMutation) SetToolName

func (m *ToolInvocationMutation) SetToolName(s string)

SetToolName sets the "tool_name" field.

func (*ToolInvocationMutation) SetToolType

func (m *ToolInvocationMutation) SetToolType(s string)

SetToolType sets the "tool_type" field.

func (*ToolInvocationMutation) SetTraceID

func (m *ToolInvocationMutation) SetTraceID(s string)

SetTraceID sets the "trace_id" field.

func (*ToolInvocationMutation) SetUpdatedAt

func (m *ToolInvocationMutation) SetUpdatedAt(t time.Time)

SetUpdatedAt sets the "updated_at" field.

func (*ToolInvocationMutation) SpanID

func (m *ToolInvocationMutation) SpanID() (r string, exists bool)

SpanID returns the value of the "span_id" field in the mutation.

func (*ToolInvocationMutation) SpanIDCleared

func (m *ToolInvocationMutation) SpanIDCleared() bool

SpanIDCleared returns if the "span_id" field was cleared in this mutation.

func (*ToolInvocationMutation) StartedAt

func (m *ToolInvocationMutation) StartedAt() (r time.Time, exists bool)

StartedAt returns the value of the "started_at" field in the mutation.

func (*ToolInvocationMutation) Status

func (m *ToolInvocationMutation) Status() (r string, exists bool)

Status returns the value of the "status" field in the mutation.

func (*ToolInvocationMutation) TaskCleared

func (m *ToolInvocationMutation) TaskCleared() bool

TaskCleared reports if the "task" edge to the AgentTask entity was cleared.

func (*ToolInvocationMutation) TaskID

func (m *ToolInvocationMutation) TaskID() (r string, exists bool)

TaskID returns the value of the "task_id" field in the mutation.

func (*ToolInvocationMutation) TaskIDCleared

func (m *ToolInvocationMutation) TaskIDCleared() bool

TaskIDCleared returns if the "task_id" field was cleared in this mutation.

func (*ToolInvocationMutation) TaskIDs

func (m *ToolInvocationMutation) TaskIDs() (ids []string)

TaskIDs returns the "task" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use TaskID instead. It exists only for internal usage by the builders.

func (*ToolInvocationMutation) ToolName

func (m *ToolInvocationMutation) ToolName() (r string, exists bool)

ToolName returns the value of the "tool_name" field in the mutation.

func (*ToolInvocationMutation) ToolType

func (m *ToolInvocationMutation) ToolType() (r string, exists bool)

ToolType returns the value of the "tool_type" field in the mutation.

func (*ToolInvocationMutation) ToolTypeCleared

func (m *ToolInvocationMutation) ToolTypeCleared() bool

ToolTypeCleared returns if the "tool_type" field was cleared in this mutation.

func (*ToolInvocationMutation) TraceID

func (m *ToolInvocationMutation) TraceID() (r string, exists bool)

TraceID returns the value of the "trace_id" field in the mutation.

func (*ToolInvocationMutation) TraceIDCleared

func (m *ToolInvocationMutation) TraceIDCleared() bool

TraceIDCleared returns if the "trace_id" field was cleared in this mutation.

func (ToolInvocationMutation) Tx

func (m ToolInvocationMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*ToolInvocationMutation) Type

func (m *ToolInvocationMutation) Type() string

Type returns the node type of this mutation (ToolInvocation).

func (*ToolInvocationMutation) UpdatedAt

func (m *ToolInvocationMutation) UpdatedAt() (r time.Time, exists bool)

UpdatedAt returns the value of the "updated_at" field in the mutation.

func (*ToolInvocationMutation) Where

Where appends a list predicates to the ToolInvocationMutation builder.

func (*ToolInvocationMutation) WhereP

func (m *ToolInvocationMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the ToolInvocationMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type ToolInvocationQuery

type ToolInvocationQuery struct {
	// contains filtered or unexported fields
}

ToolInvocationQuery is the builder for querying ToolInvocation entities.

func (*ToolInvocationQuery) Aggregate

func (tiq *ToolInvocationQuery) Aggregate(fns ...AggregateFunc) *ToolInvocationSelect

Aggregate returns a ToolInvocationSelect configured with the given aggregations.

func (*ToolInvocationQuery) All

All executes the query and returns a list of ToolInvocations.

func (*ToolInvocationQuery) AllX

AllX is like All, but panics if an error occurs.

func (*ToolInvocationQuery) Clone

Clone returns a duplicate of the ToolInvocationQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*ToolInvocationQuery) Count

func (tiq *ToolInvocationQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*ToolInvocationQuery) CountX

func (tiq *ToolInvocationQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*ToolInvocationQuery) Exist

func (tiq *ToolInvocationQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*ToolInvocationQuery) ExistX

func (tiq *ToolInvocationQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*ToolInvocationQuery) First

First returns the first ToolInvocation entity from the query. Returns a *NotFoundError when no ToolInvocation was found.

func (*ToolInvocationQuery) FirstID

func (tiq *ToolInvocationQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first ToolInvocation ID from the query. Returns a *NotFoundError when no ToolInvocation ID was found.

func (*ToolInvocationQuery) FirstIDX

func (tiq *ToolInvocationQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*ToolInvocationQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*ToolInvocationQuery) GroupBy

func (tiq *ToolInvocationQuery) GroupBy(field string, fields ...string) *ToolInvocationGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	TaskID string `json:"task_id,omitempty"`
	Count int `json:"count,omitempty"`
}

client.ToolInvocation.Query().
	GroupBy(toolinvocation.FieldTaskID).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*ToolInvocationQuery) IDs

func (tiq *ToolInvocationQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of ToolInvocation IDs.

func (*ToolInvocationQuery) IDsX

func (tiq *ToolInvocationQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*ToolInvocationQuery) Limit

func (tiq *ToolInvocationQuery) Limit(limit int) *ToolInvocationQuery

Limit the number of records to be returned by this query.

func (*ToolInvocationQuery) Offset

func (tiq *ToolInvocationQuery) Offset(offset int) *ToolInvocationQuery

Offset to start from.

func (*ToolInvocationQuery) Only

Only returns a single ToolInvocation entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one ToolInvocation entity is found. Returns a *NotFoundError when no ToolInvocation entities are found.

func (*ToolInvocationQuery) OnlyID

func (tiq *ToolInvocationQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only ToolInvocation ID in the query. Returns a *NotSingularError when more than one ToolInvocation ID is found. Returns a *NotFoundError when no entities are found.

func (*ToolInvocationQuery) OnlyIDX

func (tiq *ToolInvocationQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*ToolInvocationQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*ToolInvocationQuery) Order

Order specifies how the records should be ordered.

func (*ToolInvocationQuery) QueryTask

func (tiq *ToolInvocationQuery) QueryTask() *AgentTaskQuery

QueryTask chains the current query on the "task" edge.

func (*ToolInvocationQuery) Select

func (tiq *ToolInvocationQuery) Select(fields ...string) *ToolInvocationSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	TaskID string `json:"task_id,omitempty"`
}

client.ToolInvocation.Query().
	Select(toolinvocation.FieldTaskID).
	Scan(ctx, &v)

func (*ToolInvocationQuery) Unique

func (tiq *ToolInvocationQuery) Unique(unique bool) *ToolInvocationQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*ToolInvocationQuery) Where

Where adds a new predicate for the ToolInvocationQuery builder.

func (*ToolInvocationQuery) WithTask

func (tiq *ToolInvocationQuery) WithTask(opts ...func(*AgentTaskQuery)) *ToolInvocationQuery

WithTask tells the query-builder to eager-load the nodes that are connected to the "task" edge. The optional arguments are used to configure the query builder of the edge.

type ToolInvocationSelect

type ToolInvocationSelect struct {
	*ToolInvocationQuery
	// contains filtered or unexported fields
}

ToolInvocationSelect is the builder for selecting fields of ToolInvocation entities.

func (*ToolInvocationSelect) Aggregate

Aggregate adds the given aggregation functions to the selector query.

func (*ToolInvocationSelect) Bool

func (s *ToolInvocationSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ToolInvocationSelect) BoolX

func (s *ToolInvocationSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ToolInvocationSelect) Bools

func (s *ToolInvocationSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ToolInvocationSelect) BoolsX

func (s *ToolInvocationSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ToolInvocationSelect) Float64

func (s *ToolInvocationSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ToolInvocationSelect) Float64X

func (s *ToolInvocationSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ToolInvocationSelect) Float64s

func (s *ToolInvocationSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ToolInvocationSelect) Float64sX

func (s *ToolInvocationSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ToolInvocationSelect) Int

func (s *ToolInvocationSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ToolInvocationSelect) IntX

func (s *ToolInvocationSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ToolInvocationSelect) Ints

func (s *ToolInvocationSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ToolInvocationSelect) IntsX

func (s *ToolInvocationSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ToolInvocationSelect) Scan

func (tis *ToolInvocationSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*ToolInvocationSelect) ScanX

func (s *ToolInvocationSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*ToolInvocationSelect) String

func (s *ToolInvocationSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ToolInvocationSelect) StringX

func (s *ToolInvocationSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ToolInvocationSelect) Strings

func (s *ToolInvocationSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ToolInvocationSelect) StringsX

func (s *ToolInvocationSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ToolInvocationUpdate

type ToolInvocationUpdate struct {
	// contains filtered or unexported fields
}

ToolInvocationUpdate is the builder for updating ToolInvocation entities.

func (*ToolInvocationUpdate) AddDurationMs

func (tiu *ToolInvocationUpdate) AddDurationMs(i int64) *ToolInvocationUpdate

AddDurationMs adds i to the "duration_ms" field.

func (*ToolInvocationUpdate) AddHTTPStatusCode

func (tiu *ToolInvocationUpdate) AddHTTPStatusCode(i int) *ToolInvocationUpdate

AddHTTPStatusCode adds i to the "http_status_code" field.

func (*ToolInvocationUpdate) AddRequestSizeBytes

func (tiu *ToolInvocationUpdate) AddRequestSizeBytes(i int) *ToolInvocationUpdate

AddRequestSizeBytes adds i to the "request_size_bytes" field.

func (*ToolInvocationUpdate) AddResponseSizeBytes

func (tiu *ToolInvocationUpdate) AddResponseSizeBytes(i int) *ToolInvocationUpdate

AddResponseSizeBytes adds i to the "response_size_bytes" field.

func (*ToolInvocationUpdate) AddRetryCount

func (tiu *ToolInvocationUpdate) AddRetryCount(i int) *ToolInvocationUpdate

AddRetryCount adds i to the "retry_count" field.

func (*ToolInvocationUpdate) ClearDurationMs

func (tiu *ToolInvocationUpdate) ClearDurationMs() *ToolInvocationUpdate

ClearDurationMs clears the value of the "duration_ms" field.

func (*ToolInvocationUpdate) ClearEndedAt

func (tiu *ToolInvocationUpdate) ClearEndedAt() *ToolInvocationUpdate

ClearEndedAt clears the value of the "ended_at" field.

func (*ToolInvocationUpdate) ClearErrorMessage

func (tiu *ToolInvocationUpdate) ClearErrorMessage() *ToolInvocationUpdate

ClearErrorMessage clears the value of the "error_message" field.

func (*ToolInvocationUpdate) ClearErrorType

func (tiu *ToolInvocationUpdate) ClearErrorType() *ToolInvocationUpdate

ClearErrorType clears the value of the "error_type" field.

func (*ToolInvocationUpdate) ClearHTTPMethod

func (tiu *ToolInvocationUpdate) ClearHTTPMethod() *ToolInvocationUpdate

ClearHTTPMethod clears the value of the "http_method" field.

func (*ToolInvocationUpdate) ClearHTTPStatusCode

func (tiu *ToolInvocationUpdate) ClearHTTPStatusCode() *ToolInvocationUpdate

ClearHTTPStatusCode clears the value of the "http_status_code" field.

func (*ToolInvocationUpdate) ClearHTTPURL

func (tiu *ToolInvocationUpdate) ClearHTTPURL() *ToolInvocationUpdate

ClearHTTPURL clears the value of the "http_url" field.

func (*ToolInvocationUpdate) ClearInput

func (tiu *ToolInvocationUpdate) ClearInput() *ToolInvocationUpdate

ClearInput clears the value of the "input" field.

func (*ToolInvocationUpdate) ClearMetadata

func (tiu *ToolInvocationUpdate) ClearMetadata() *ToolInvocationUpdate

ClearMetadata clears the value of the "metadata" field.

func (*ToolInvocationUpdate) ClearOutput

func (tiu *ToolInvocationUpdate) ClearOutput() *ToolInvocationUpdate

ClearOutput clears the value of the "output" field.

func (*ToolInvocationUpdate) ClearSpanID

func (tiu *ToolInvocationUpdate) ClearSpanID() *ToolInvocationUpdate

ClearSpanID clears the value of the "span_id" field.

func (*ToolInvocationUpdate) ClearTask

func (tiu *ToolInvocationUpdate) ClearTask() *ToolInvocationUpdate

ClearTask clears the "task" edge to the AgentTask entity.

func (*ToolInvocationUpdate) ClearTaskID

func (tiu *ToolInvocationUpdate) ClearTaskID() *ToolInvocationUpdate

ClearTaskID clears the value of the "task_id" field.

func (*ToolInvocationUpdate) ClearToolType

func (tiu *ToolInvocationUpdate) ClearToolType() *ToolInvocationUpdate

ClearToolType clears the value of the "tool_type" field.

func (*ToolInvocationUpdate) ClearTraceID

func (tiu *ToolInvocationUpdate) ClearTraceID() *ToolInvocationUpdate

ClearTraceID clears the value of the "trace_id" field.

func (*ToolInvocationUpdate) Exec

func (tiu *ToolInvocationUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*ToolInvocationUpdate) ExecX

func (tiu *ToolInvocationUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ToolInvocationUpdate) Mutation

Mutation returns the ToolInvocationMutation object of the builder.

func (*ToolInvocationUpdate) Save

func (tiu *ToolInvocationUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*ToolInvocationUpdate) SaveX

func (tiu *ToolInvocationUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*ToolInvocationUpdate) SetAgentID

func (tiu *ToolInvocationUpdate) SetAgentID(s string) *ToolInvocationUpdate

SetAgentID sets the "agent_id" field.

func (*ToolInvocationUpdate) SetDurationMs

func (tiu *ToolInvocationUpdate) SetDurationMs(i int64) *ToolInvocationUpdate

SetDurationMs sets the "duration_ms" field.

func (*ToolInvocationUpdate) SetEndedAt

func (tiu *ToolInvocationUpdate) SetEndedAt(t time.Time) *ToolInvocationUpdate

SetEndedAt sets the "ended_at" field.

func (*ToolInvocationUpdate) SetErrorMessage

func (tiu *ToolInvocationUpdate) SetErrorMessage(s string) *ToolInvocationUpdate

SetErrorMessage sets the "error_message" field.

func (*ToolInvocationUpdate) SetErrorType

func (tiu *ToolInvocationUpdate) SetErrorType(s string) *ToolInvocationUpdate

SetErrorType sets the "error_type" field.

func (*ToolInvocationUpdate) SetHTTPMethod

func (tiu *ToolInvocationUpdate) SetHTTPMethod(s string) *ToolInvocationUpdate

SetHTTPMethod sets the "http_method" field.

func (*ToolInvocationUpdate) SetHTTPStatusCode

func (tiu *ToolInvocationUpdate) SetHTTPStatusCode(i int) *ToolInvocationUpdate

SetHTTPStatusCode sets the "http_status_code" field.

func (*ToolInvocationUpdate) SetHTTPURL

func (tiu *ToolInvocationUpdate) SetHTTPURL(s string) *ToolInvocationUpdate

SetHTTPURL sets the "http_url" field.

func (*ToolInvocationUpdate) SetInput

func (tiu *ToolInvocationUpdate) SetInput(m map[string]interface{}) *ToolInvocationUpdate

SetInput sets the "input" field.

func (*ToolInvocationUpdate) SetMetadata

func (tiu *ToolInvocationUpdate) SetMetadata(m map[string]interface{}) *ToolInvocationUpdate

SetMetadata sets the "metadata" field.

func (*ToolInvocationUpdate) SetNillableAgentID

func (tiu *ToolInvocationUpdate) SetNillableAgentID(s *string) *ToolInvocationUpdate

SetNillableAgentID sets the "agent_id" field if the given value is not nil.

func (*ToolInvocationUpdate) SetNillableDurationMs

func (tiu *ToolInvocationUpdate) SetNillableDurationMs(i *int64) *ToolInvocationUpdate

SetNillableDurationMs sets the "duration_ms" field if the given value is not nil.

func (*ToolInvocationUpdate) SetNillableEndedAt

func (tiu *ToolInvocationUpdate) SetNillableEndedAt(t *time.Time) *ToolInvocationUpdate

SetNillableEndedAt sets the "ended_at" field if the given value is not nil.

func (*ToolInvocationUpdate) SetNillableErrorMessage

func (tiu *ToolInvocationUpdate) SetNillableErrorMessage(s *string) *ToolInvocationUpdate

SetNillableErrorMessage sets the "error_message" field if the given value is not nil.

func (*ToolInvocationUpdate) SetNillableErrorType

func (tiu *ToolInvocationUpdate) SetNillableErrorType(s *string) *ToolInvocationUpdate

SetNillableErrorType sets the "error_type" field if the given value is not nil.

func (*ToolInvocationUpdate) SetNillableHTTPMethod

func (tiu *ToolInvocationUpdate) SetNillableHTTPMethod(s *string) *ToolInvocationUpdate

SetNillableHTTPMethod sets the "http_method" field if the given value is not nil.

func (*ToolInvocationUpdate) SetNillableHTTPStatusCode

func (tiu *ToolInvocationUpdate) SetNillableHTTPStatusCode(i *int) *ToolInvocationUpdate

SetNillableHTTPStatusCode sets the "http_status_code" field if the given value is not nil.

func (*ToolInvocationUpdate) SetNillableHTTPURL

func (tiu *ToolInvocationUpdate) SetNillableHTTPURL(s *string) *ToolInvocationUpdate

SetNillableHTTPURL sets the "http_url" field if the given value is not nil.

func (*ToolInvocationUpdate) SetNillableRequestSizeBytes

func (tiu *ToolInvocationUpdate) SetNillableRequestSizeBytes(i *int) *ToolInvocationUpdate

SetNillableRequestSizeBytes sets the "request_size_bytes" field if the given value is not nil.

func (*ToolInvocationUpdate) SetNillableResponseSizeBytes

func (tiu *ToolInvocationUpdate) SetNillableResponseSizeBytes(i *int) *ToolInvocationUpdate

SetNillableResponseSizeBytes sets the "response_size_bytes" field if the given value is not nil.

func (*ToolInvocationUpdate) SetNillableRetryCount

func (tiu *ToolInvocationUpdate) SetNillableRetryCount(i *int) *ToolInvocationUpdate

SetNillableRetryCount sets the "retry_count" field if the given value is not nil.

func (*ToolInvocationUpdate) SetNillableSpanID

func (tiu *ToolInvocationUpdate) SetNillableSpanID(s *string) *ToolInvocationUpdate

SetNillableSpanID sets the "span_id" field if the given value is not nil.

func (*ToolInvocationUpdate) SetNillableStatus

func (tiu *ToolInvocationUpdate) SetNillableStatus(s *string) *ToolInvocationUpdate

SetNillableStatus sets the "status" field if the given value is not nil.

func (*ToolInvocationUpdate) SetNillableTaskID

func (tiu *ToolInvocationUpdate) SetNillableTaskID(s *string) *ToolInvocationUpdate

SetNillableTaskID sets the "task_id" field if the given value is not nil.

func (*ToolInvocationUpdate) SetNillableToolName

func (tiu *ToolInvocationUpdate) SetNillableToolName(s *string) *ToolInvocationUpdate

SetNillableToolName sets the "tool_name" field if the given value is not nil.

func (*ToolInvocationUpdate) SetNillableToolType

func (tiu *ToolInvocationUpdate) SetNillableToolType(s *string) *ToolInvocationUpdate

SetNillableToolType sets the "tool_type" field if the given value is not nil.

func (*ToolInvocationUpdate) SetNillableTraceID

func (tiu *ToolInvocationUpdate) SetNillableTraceID(s *string) *ToolInvocationUpdate

SetNillableTraceID sets the "trace_id" field if the given value is not nil.

func (*ToolInvocationUpdate) SetOutput

func (tiu *ToolInvocationUpdate) SetOutput(m map[string]interface{}) *ToolInvocationUpdate

SetOutput sets the "output" field.

func (*ToolInvocationUpdate) SetRequestSizeBytes

func (tiu *ToolInvocationUpdate) SetRequestSizeBytes(i int) *ToolInvocationUpdate

SetRequestSizeBytes sets the "request_size_bytes" field.

func (*ToolInvocationUpdate) SetResponseSizeBytes

func (tiu *ToolInvocationUpdate) SetResponseSizeBytes(i int) *ToolInvocationUpdate

SetResponseSizeBytes sets the "response_size_bytes" field.

func (*ToolInvocationUpdate) SetRetryCount

func (tiu *ToolInvocationUpdate) SetRetryCount(i int) *ToolInvocationUpdate

SetRetryCount sets the "retry_count" field.

func (*ToolInvocationUpdate) SetSpanID

SetSpanID sets the "span_id" field.

func (*ToolInvocationUpdate) SetStatus

SetStatus sets the "status" field.

func (*ToolInvocationUpdate) SetTask

SetTask sets the "task" edge to the AgentTask entity.

func (*ToolInvocationUpdate) SetTaskID

SetTaskID sets the "task_id" field.

func (*ToolInvocationUpdate) SetToolName

func (tiu *ToolInvocationUpdate) SetToolName(s string) *ToolInvocationUpdate

SetToolName sets the "tool_name" field.

func (*ToolInvocationUpdate) SetToolType

func (tiu *ToolInvocationUpdate) SetToolType(s string) *ToolInvocationUpdate

SetToolType sets the "tool_type" field.

func (*ToolInvocationUpdate) SetTraceID

func (tiu *ToolInvocationUpdate) SetTraceID(s string) *ToolInvocationUpdate

SetTraceID sets the "trace_id" field.

func (*ToolInvocationUpdate) SetUpdatedAt

func (tiu *ToolInvocationUpdate) SetUpdatedAt(t time.Time) *ToolInvocationUpdate

SetUpdatedAt sets the "updated_at" field.

func (*ToolInvocationUpdate) Where

Where appends a list predicates to the ToolInvocationUpdate builder.

type ToolInvocationUpdateOne

type ToolInvocationUpdateOne struct {
	// contains filtered or unexported fields
}

ToolInvocationUpdateOne is the builder for updating a single ToolInvocation entity.

func (*ToolInvocationUpdateOne) AddDurationMs

func (tiuo *ToolInvocationUpdateOne) AddDurationMs(i int64) *ToolInvocationUpdateOne

AddDurationMs adds i to the "duration_ms" field.

func (*ToolInvocationUpdateOne) AddHTTPStatusCode

func (tiuo *ToolInvocationUpdateOne) AddHTTPStatusCode(i int) *ToolInvocationUpdateOne

AddHTTPStatusCode adds i to the "http_status_code" field.

func (*ToolInvocationUpdateOne) AddRequestSizeBytes

func (tiuo *ToolInvocationUpdateOne) AddRequestSizeBytes(i int) *ToolInvocationUpdateOne

AddRequestSizeBytes adds i to the "request_size_bytes" field.

func (*ToolInvocationUpdateOne) AddResponseSizeBytes

func (tiuo *ToolInvocationUpdateOne) AddResponseSizeBytes(i int) *ToolInvocationUpdateOne

AddResponseSizeBytes adds i to the "response_size_bytes" field.

func (*ToolInvocationUpdateOne) AddRetryCount

func (tiuo *ToolInvocationUpdateOne) AddRetryCount(i int) *ToolInvocationUpdateOne

AddRetryCount adds i to the "retry_count" field.

func (*ToolInvocationUpdateOne) ClearDurationMs

func (tiuo *ToolInvocationUpdateOne) ClearDurationMs() *ToolInvocationUpdateOne

ClearDurationMs clears the value of the "duration_ms" field.

func (*ToolInvocationUpdateOne) ClearEndedAt

func (tiuo *ToolInvocationUpdateOne) ClearEndedAt() *ToolInvocationUpdateOne

ClearEndedAt clears the value of the "ended_at" field.

func (*ToolInvocationUpdateOne) ClearErrorMessage

func (tiuo *ToolInvocationUpdateOne) ClearErrorMessage() *ToolInvocationUpdateOne

ClearErrorMessage clears the value of the "error_message" field.

func (*ToolInvocationUpdateOne) ClearErrorType

func (tiuo *ToolInvocationUpdateOne) ClearErrorType() *ToolInvocationUpdateOne

ClearErrorType clears the value of the "error_type" field.

func (*ToolInvocationUpdateOne) ClearHTTPMethod

func (tiuo *ToolInvocationUpdateOne) ClearHTTPMethod() *ToolInvocationUpdateOne

ClearHTTPMethod clears the value of the "http_method" field.

func (*ToolInvocationUpdateOne) ClearHTTPStatusCode

func (tiuo *ToolInvocationUpdateOne) ClearHTTPStatusCode() *ToolInvocationUpdateOne

ClearHTTPStatusCode clears the value of the "http_status_code" field.

func (*ToolInvocationUpdateOne) ClearHTTPURL

func (tiuo *ToolInvocationUpdateOne) ClearHTTPURL() *ToolInvocationUpdateOne

ClearHTTPURL clears the value of the "http_url" field.

func (*ToolInvocationUpdateOne) ClearInput

ClearInput clears the value of the "input" field.

func (*ToolInvocationUpdateOne) ClearMetadata

func (tiuo *ToolInvocationUpdateOne) ClearMetadata() *ToolInvocationUpdateOne

ClearMetadata clears the value of the "metadata" field.

func (*ToolInvocationUpdateOne) ClearOutput

func (tiuo *ToolInvocationUpdateOne) ClearOutput() *ToolInvocationUpdateOne

ClearOutput clears the value of the "output" field.

func (*ToolInvocationUpdateOne) ClearSpanID

func (tiuo *ToolInvocationUpdateOne) ClearSpanID() *ToolInvocationUpdateOne

ClearSpanID clears the value of the "span_id" field.

func (*ToolInvocationUpdateOne) ClearTask

ClearTask clears the "task" edge to the AgentTask entity.

func (*ToolInvocationUpdateOne) ClearTaskID

func (tiuo *ToolInvocationUpdateOne) ClearTaskID() *ToolInvocationUpdateOne

ClearTaskID clears the value of the "task_id" field.

func (*ToolInvocationUpdateOne) ClearToolType

func (tiuo *ToolInvocationUpdateOne) ClearToolType() *ToolInvocationUpdateOne

ClearToolType clears the value of the "tool_type" field.

func (*ToolInvocationUpdateOne) ClearTraceID

func (tiuo *ToolInvocationUpdateOne) ClearTraceID() *ToolInvocationUpdateOne

ClearTraceID clears the value of the "trace_id" field.

func (*ToolInvocationUpdateOne) Exec

func (tiuo *ToolInvocationUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*ToolInvocationUpdateOne) ExecX

func (tiuo *ToolInvocationUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ToolInvocationUpdateOne) Mutation

Mutation returns the ToolInvocationMutation object of the builder.

func (*ToolInvocationUpdateOne) Save

Save executes the query and returns the updated ToolInvocation entity.

func (*ToolInvocationUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*ToolInvocationUpdateOne) Select

func (tiuo *ToolInvocationUpdateOne) Select(field string, fields ...string) *ToolInvocationUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*ToolInvocationUpdateOne) SetAgentID

SetAgentID sets the "agent_id" field.

func (*ToolInvocationUpdateOne) SetDurationMs

func (tiuo *ToolInvocationUpdateOne) SetDurationMs(i int64) *ToolInvocationUpdateOne

SetDurationMs sets the "duration_ms" field.

func (*ToolInvocationUpdateOne) SetEndedAt

SetEndedAt sets the "ended_at" field.

func (*ToolInvocationUpdateOne) SetErrorMessage

func (tiuo *ToolInvocationUpdateOne) SetErrorMessage(s string) *ToolInvocationUpdateOne

SetErrorMessage sets the "error_message" field.

func (*ToolInvocationUpdateOne) SetErrorType

SetErrorType sets the "error_type" field.

func (*ToolInvocationUpdateOne) SetHTTPMethod

func (tiuo *ToolInvocationUpdateOne) SetHTTPMethod(s string) *ToolInvocationUpdateOne

SetHTTPMethod sets the "http_method" field.

func (*ToolInvocationUpdateOne) SetHTTPStatusCode

func (tiuo *ToolInvocationUpdateOne) SetHTTPStatusCode(i int) *ToolInvocationUpdateOne

SetHTTPStatusCode sets the "http_status_code" field.

func (*ToolInvocationUpdateOne) SetHTTPURL

SetHTTPURL sets the "http_url" field.

func (*ToolInvocationUpdateOne) SetInput

func (tiuo *ToolInvocationUpdateOne) SetInput(m map[string]interface{}) *ToolInvocationUpdateOne

SetInput sets the "input" field.

func (*ToolInvocationUpdateOne) SetMetadata

func (tiuo *ToolInvocationUpdateOne) SetMetadata(m map[string]interface{}) *ToolInvocationUpdateOne

SetMetadata sets the "metadata" field.

func (*ToolInvocationUpdateOne) SetNillableAgentID

func (tiuo *ToolInvocationUpdateOne) SetNillableAgentID(s *string) *ToolInvocationUpdateOne

SetNillableAgentID sets the "agent_id" field if the given value is not nil.

func (*ToolInvocationUpdateOne) SetNillableDurationMs

func (tiuo *ToolInvocationUpdateOne) SetNillableDurationMs(i *int64) *ToolInvocationUpdateOne

SetNillableDurationMs sets the "duration_ms" field if the given value is not nil.

func (*ToolInvocationUpdateOne) SetNillableEndedAt

func (tiuo *ToolInvocationUpdateOne) SetNillableEndedAt(t *time.Time) *ToolInvocationUpdateOne

SetNillableEndedAt sets the "ended_at" field if the given value is not nil.

func (*ToolInvocationUpdateOne) SetNillableErrorMessage

func (tiuo *ToolInvocationUpdateOne) SetNillableErrorMessage(s *string) *ToolInvocationUpdateOne

SetNillableErrorMessage sets the "error_message" field if the given value is not nil.

func (*ToolInvocationUpdateOne) SetNillableErrorType

func (tiuo *ToolInvocationUpdateOne) SetNillableErrorType(s *string) *ToolInvocationUpdateOne

SetNillableErrorType sets the "error_type" field if the given value is not nil.

func (*ToolInvocationUpdateOne) SetNillableHTTPMethod

func (tiuo *ToolInvocationUpdateOne) SetNillableHTTPMethod(s *string) *ToolInvocationUpdateOne

SetNillableHTTPMethod sets the "http_method" field if the given value is not nil.

func (*ToolInvocationUpdateOne) SetNillableHTTPStatusCode

func (tiuo *ToolInvocationUpdateOne) SetNillableHTTPStatusCode(i *int) *ToolInvocationUpdateOne

SetNillableHTTPStatusCode sets the "http_status_code" field if the given value is not nil.

func (*ToolInvocationUpdateOne) SetNillableHTTPURL

func (tiuo *ToolInvocationUpdateOne) SetNillableHTTPURL(s *string) *ToolInvocationUpdateOne

SetNillableHTTPURL sets the "http_url" field if the given value is not nil.

func (*ToolInvocationUpdateOne) SetNillableRequestSizeBytes

func (tiuo *ToolInvocationUpdateOne) SetNillableRequestSizeBytes(i *int) *ToolInvocationUpdateOne

SetNillableRequestSizeBytes sets the "request_size_bytes" field if the given value is not nil.

func (*ToolInvocationUpdateOne) SetNillableResponseSizeBytes

func (tiuo *ToolInvocationUpdateOne) SetNillableResponseSizeBytes(i *int) *ToolInvocationUpdateOne

SetNillableResponseSizeBytes sets the "response_size_bytes" field if the given value is not nil.

func (*ToolInvocationUpdateOne) SetNillableRetryCount

func (tiuo *ToolInvocationUpdateOne) SetNillableRetryCount(i *int) *ToolInvocationUpdateOne

SetNillableRetryCount sets the "retry_count" field if the given value is not nil.

func (*ToolInvocationUpdateOne) SetNillableSpanID

func (tiuo *ToolInvocationUpdateOne) SetNillableSpanID(s *string) *ToolInvocationUpdateOne

SetNillableSpanID sets the "span_id" field if the given value is not nil.

func (*ToolInvocationUpdateOne) SetNillableStatus

func (tiuo *ToolInvocationUpdateOne) SetNillableStatus(s *string) *ToolInvocationUpdateOne

SetNillableStatus sets the "status" field if the given value is not nil.

func (*ToolInvocationUpdateOne) SetNillableTaskID

func (tiuo *ToolInvocationUpdateOne) SetNillableTaskID(s *string) *ToolInvocationUpdateOne

SetNillableTaskID sets the "task_id" field if the given value is not nil.

func (*ToolInvocationUpdateOne) SetNillableToolName

func (tiuo *ToolInvocationUpdateOne) SetNillableToolName(s *string) *ToolInvocationUpdateOne

SetNillableToolName sets the "tool_name" field if the given value is not nil.

func (*ToolInvocationUpdateOne) SetNillableToolType

func (tiuo *ToolInvocationUpdateOne) SetNillableToolType(s *string) *ToolInvocationUpdateOne

SetNillableToolType sets the "tool_type" field if the given value is not nil.

func (*ToolInvocationUpdateOne) SetNillableTraceID

func (tiuo *ToolInvocationUpdateOne) SetNillableTraceID(s *string) *ToolInvocationUpdateOne

SetNillableTraceID sets the "trace_id" field if the given value is not nil.

func (*ToolInvocationUpdateOne) SetOutput

func (tiuo *ToolInvocationUpdateOne) SetOutput(m map[string]interface{}) *ToolInvocationUpdateOne

SetOutput sets the "output" field.

func (*ToolInvocationUpdateOne) SetRequestSizeBytes

func (tiuo *ToolInvocationUpdateOne) SetRequestSizeBytes(i int) *ToolInvocationUpdateOne

SetRequestSizeBytes sets the "request_size_bytes" field.

func (*ToolInvocationUpdateOne) SetResponseSizeBytes

func (tiuo *ToolInvocationUpdateOne) SetResponseSizeBytes(i int) *ToolInvocationUpdateOne

SetResponseSizeBytes sets the "response_size_bytes" field.

func (*ToolInvocationUpdateOne) SetRetryCount

func (tiuo *ToolInvocationUpdateOne) SetRetryCount(i int) *ToolInvocationUpdateOne

SetRetryCount sets the "retry_count" field.

func (*ToolInvocationUpdateOne) SetSpanID

SetSpanID sets the "span_id" field.

func (*ToolInvocationUpdateOne) SetStatus

SetStatus sets the "status" field.

func (*ToolInvocationUpdateOne) SetTask

SetTask sets the "task" edge to the AgentTask entity.

func (*ToolInvocationUpdateOne) SetTaskID

SetTaskID sets the "task_id" field.

func (*ToolInvocationUpdateOne) SetToolName

SetToolName sets the "tool_name" field.

func (*ToolInvocationUpdateOne) SetToolType

SetToolType sets the "tool_type" field.

func (*ToolInvocationUpdateOne) SetTraceID

SetTraceID sets the "trace_id" field.

func (*ToolInvocationUpdateOne) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*ToolInvocationUpdateOne) Where

Where appends a list predicates to the ToolInvocationUpdate builder.

type ToolInvocations

type ToolInvocations []*ToolInvocation

ToolInvocations is a parsable slice of ToolInvocation.

type TraverseFunc

type TraverseFunc = ent.TraverseFunc

ent aliases to avoid import conflicts in user's code.

type Traverser

type Traverser = ent.Traverser

ent aliases to avoid import conflicts in user's code.

type Tx

type Tx struct {

	// AgentEvent is the client for interacting with the AgentEvent builders.
	AgentEvent *AgentEventClient
	// AgentHandoff is the client for interacting with the AgentHandoff builders.
	AgentHandoff *AgentHandoffClient
	// AgentTask is the client for interacting with the AgentTask builders.
	AgentTask *AgentTaskClient
	// ToolInvocation is the client for interacting with the ToolInvocation builders.
	ToolInvocation *ToolInvocationClient
	// Workflow is the client for interacting with the Workflow builders.
	Workflow *WorkflowClient
	// contains filtered or unexported fields
}

Tx is a transactional client that is created by calling Client.Tx().

func TxFromContext

func TxFromContext(ctx context.Context) *Tx

TxFromContext returns a Tx stored inside a context, or nil if there isn't one.

func (*Tx) Client

func (tx *Tx) Client() *Client

Client returns a Client that binds to current transaction.

func (*Tx) Commit

func (tx *Tx) Commit() error

Commit commits the transaction.

func (*Tx) OnCommit

func (tx *Tx) OnCommit(f CommitHook)

OnCommit adds a hook to call on commit.

func (*Tx) OnRollback

func (tx *Tx) OnRollback(f RollbackHook)

OnRollback adds a hook to call on rollback.

func (*Tx) Rollback

func (tx *Tx) Rollback() error

Rollback rollbacks the transaction.

type ValidationError

type ValidationError struct {
	Name string // Field or edge name.
	// contains filtered or unexported fields
}

ValidationError returns when validating a field or edge fails.

func (*ValidationError) Error

func (e *ValidationError) Error() string

Error implements the error interface.

func (*ValidationError) Unwrap

func (e *ValidationError) Unwrap() error

Unwrap implements the errors.Wrapper interface.

type Value

type Value = ent.Value

ent aliases to avoid import conflicts in user's code.

type Workflow

type Workflow struct {

	// ID of the ent.
	// Unique workflow identifier (UUID)
	ID string `json:"id,omitempty"`
	// Workflow name/type (e.g., 'statistics-extraction')
	Name string `json:"name,omitempty"`
	// Workflow status: running, completed, failed, cancelled
	Status string `json:"status,omitempty"`
	// OpenTelemetry trace ID for correlation
	TraceID string `json:"trace_id,omitempty"`
	// Parent workflow ID for nested workflows
	ParentWorkflowID string `json:"parent_workflow_id,omitempty"`
	// What initiated the workflow (user_id, api_key, system)
	Initiator string `json:"initiator,omitempty"`
	// Workflow input data
	Input map[string]interface{} `json:"input,omitempty"`
	// Workflow output/result data
	Output map[string]interface{} `json:"output,omitempty"`
	// Additional metadata
	Metadata map[string]interface{} `json:"metadata,omitempty"`
	// Number of tasks in this workflow
	TaskCount int `json:"task_count,omitempty"`
	// Number of completed tasks
	CompletedTaskCount int `json:"completed_task_count,omitempty"`
	// Number of failed tasks
	FailedTaskCount int `json:"failed_task_count,omitempty"`
	// Total cost in USD
	TotalCostUsd float64 `json:"total_cost_usd,omitempty"`
	// Total LLM tokens used
	TotalTokens int `json:"total_tokens,omitempty"`
	// Total duration in milliseconds
	DurationMs int64 `json:"duration_ms,omitempty"`
	// Error message if workflow failed
	ErrorMessage string `json:"error_message,omitempty"`
	// When the workflow started
	StartedAt time.Time `json:"started_at,omitempty"`
	// When the workflow ended
	EndedAt *time.Time `json:"ended_at,omitempty"`
	// CreatedAt holds the value of the "created_at" field.
	CreatedAt time.Time `json:"created_at,omitempty"`
	// UpdatedAt holds the value of the "updated_at" field.
	UpdatedAt time.Time `json:"updated_at,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the WorkflowQuery when eager-loading is set.
	Edges WorkflowEdges `json:"edges"`
	// contains filtered or unexported fields
}

Workflow is the model entity for the Workflow schema.

func (*Workflow) QueryEvents

func (w *Workflow) QueryEvents() *AgentEventQuery

QueryEvents queries the "events" edge of the Workflow entity.

func (*Workflow) QueryHandoffs

func (w *Workflow) QueryHandoffs() *AgentHandoffQuery

QueryHandoffs queries the "handoffs" edge of the Workflow entity.

func (*Workflow) QueryTasks

func (w *Workflow) QueryTasks() *AgentTaskQuery

QueryTasks queries the "tasks" edge of the Workflow entity.

func (*Workflow) String

func (w *Workflow) String() string

String implements the fmt.Stringer.

func (*Workflow) Unwrap

func (w *Workflow) Unwrap() *Workflow

Unwrap unwraps the Workflow entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*Workflow) Update

func (w *Workflow) Update() *WorkflowUpdateOne

Update returns a builder for updating this Workflow. Note that you need to call Workflow.Unwrap() before calling this method if this Workflow was returned from a transaction, and the transaction was committed or rolled back.

func (*Workflow) Value

func (w *Workflow) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the Workflow. This includes values selected through modifiers, order, etc.

type WorkflowClient

type WorkflowClient struct {
	// contains filtered or unexported fields
}

WorkflowClient is a client for the Workflow schema.

func NewWorkflowClient

func NewWorkflowClient(c config) *WorkflowClient

NewWorkflowClient returns a client for the Workflow from the given config.

func (*WorkflowClient) Create

func (c *WorkflowClient) Create() *WorkflowCreate

Create returns a builder for creating a Workflow entity.

func (*WorkflowClient) CreateBulk

func (c *WorkflowClient) CreateBulk(builders ...*WorkflowCreate) *WorkflowCreateBulk

CreateBulk returns a builder for creating a bulk of Workflow entities.

func (*WorkflowClient) Delete

func (c *WorkflowClient) Delete() *WorkflowDelete

Delete returns a delete builder for Workflow.

func (*WorkflowClient) DeleteOne

func (c *WorkflowClient) DeleteOne(w *Workflow) *WorkflowDeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*WorkflowClient) DeleteOneID

func (c *WorkflowClient) DeleteOneID(id string) *WorkflowDeleteOne

DeleteOneID returns a builder for deleting the given entity by its id.

func (*WorkflowClient) Get

func (c *WorkflowClient) Get(ctx context.Context, id string) (*Workflow, error)

Get returns a Workflow entity by its id.

func (*WorkflowClient) GetX

func (c *WorkflowClient) GetX(ctx context.Context, id string) *Workflow

GetX is like Get, but panics if an error occurs.

func (*WorkflowClient) Hooks

func (c *WorkflowClient) Hooks() []Hook

Hooks returns the client hooks.

func (*WorkflowClient) Intercept

func (c *WorkflowClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `workflow.Intercept(f(g(h())))`.

func (*WorkflowClient) Interceptors

func (c *WorkflowClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*WorkflowClient) MapCreateBulk

func (c *WorkflowClient) MapCreateBulk(slice any, setFunc func(*WorkflowCreate, int)) *WorkflowCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*WorkflowClient) Query

func (c *WorkflowClient) Query() *WorkflowQuery

Query returns a query builder for Workflow.

func (*WorkflowClient) QueryEvents

func (c *WorkflowClient) QueryEvents(w *Workflow) *AgentEventQuery

QueryEvents queries the events edge of a Workflow.

func (*WorkflowClient) QueryHandoffs

func (c *WorkflowClient) QueryHandoffs(w *Workflow) *AgentHandoffQuery

QueryHandoffs queries the handoffs edge of a Workflow.

func (*WorkflowClient) QueryTasks

func (c *WorkflowClient) QueryTasks(w *Workflow) *AgentTaskQuery

QueryTasks queries the tasks edge of a Workflow.

func (*WorkflowClient) Update

func (c *WorkflowClient) Update() *WorkflowUpdate

Update returns an update builder for Workflow.

func (*WorkflowClient) UpdateOne

func (c *WorkflowClient) UpdateOne(w *Workflow) *WorkflowUpdateOne

UpdateOne returns an update builder for the given entity.

func (*WorkflowClient) UpdateOneID

func (c *WorkflowClient) UpdateOneID(id string) *WorkflowUpdateOne

UpdateOneID returns an update builder for the given id.

func (*WorkflowClient) Use

func (c *WorkflowClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `workflow.Hooks(f(g(h())))`.

type WorkflowCreate

type WorkflowCreate struct {
	// contains filtered or unexported fields
}

WorkflowCreate is the builder for creating a Workflow entity.

func (*WorkflowCreate) AddEventIDs

func (wc *WorkflowCreate) AddEventIDs(ids ...string) *WorkflowCreate

AddEventIDs adds the "events" edge to the AgentEvent entity by IDs.

func (*WorkflowCreate) AddEvents

func (wc *WorkflowCreate) AddEvents(a ...*AgentEvent) *WorkflowCreate

AddEvents adds the "events" edges to the AgentEvent entity.

func (*WorkflowCreate) AddHandoffIDs

func (wc *WorkflowCreate) AddHandoffIDs(ids ...string) *WorkflowCreate

AddHandoffIDs adds the "handoffs" edge to the AgentHandoff entity by IDs.

func (*WorkflowCreate) AddHandoffs

func (wc *WorkflowCreate) AddHandoffs(a ...*AgentHandoff) *WorkflowCreate

AddHandoffs adds the "handoffs" edges to the AgentHandoff entity.

func (*WorkflowCreate) AddTaskIDs

func (wc *WorkflowCreate) AddTaskIDs(ids ...string) *WorkflowCreate

AddTaskIDs adds the "tasks" edge to the AgentTask entity by IDs.

func (*WorkflowCreate) AddTasks

func (wc *WorkflowCreate) AddTasks(a ...*AgentTask) *WorkflowCreate

AddTasks adds the "tasks" edges to the AgentTask entity.

func (*WorkflowCreate) Exec

func (wc *WorkflowCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*WorkflowCreate) ExecX

func (wc *WorkflowCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*WorkflowCreate) Mutation

func (wc *WorkflowCreate) Mutation() *WorkflowMutation

Mutation returns the WorkflowMutation object of the builder.

func (*WorkflowCreate) Save

func (wc *WorkflowCreate) Save(ctx context.Context) (*Workflow, error)

Save creates the Workflow in the database.

func (*WorkflowCreate) SaveX

func (wc *WorkflowCreate) SaveX(ctx context.Context) *Workflow

SaveX calls Save and panics if Save returns an error.

func (*WorkflowCreate) SetCompletedTaskCount

func (wc *WorkflowCreate) SetCompletedTaskCount(i int) *WorkflowCreate

SetCompletedTaskCount sets the "completed_task_count" field.

func (*WorkflowCreate) SetCreatedAt

func (wc *WorkflowCreate) SetCreatedAt(t time.Time) *WorkflowCreate

SetCreatedAt sets the "created_at" field.

func (*WorkflowCreate) SetDurationMs

func (wc *WorkflowCreate) SetDurationMs(i int64) *WorkflowCreate

SetDurationMs sets the "duration_ms" field.

func (*WorkflowCreate) SetEndedAt

func (wc *WorkflowCreate) SetEndedAt(t time.Time) *WorkflowCreate

SetEndedAt sets the "ended_at" field.

func (*WorkflowCreate) SetErrorMessage

func (wc *WorkflowCreate) SetErrorMessage(s string) *WorkflowCreate

SetErrorMessage sets the "error_message" field.

func (*WorkflowCreate) SetFailedTaskCount

func (wc *WorkflowCreate) SetFailedTaskCount(i int) *WorkflowCreate

SetFailedTaskCount sets the "failed_task_count" field.

func (*WorkflowCreate) SetID

func (wc *WorkflowCreate) SetID(s string) *WorkflowCreate

SetID sets the "id" field.

func (*WorkflowCreate) SetInitiator

func (wc *WorkflowCreate) SetInitiator(s string) *WorkflowCreate

SetInitiator sets the "initiator" field.

func (*WorkflowCreate) SetInput

func (wc *WorkflowCreate) SetInput(m map[string]interface{}) *WorkflowCreate

SetInput sets the "input" field.

func (*WorkflowCreate) SetMetadata

func (wc *WorkflowCreate) SetMetadata(m map[string]interface{}) *WorkflowCreate

SetMetadata sets the "metadata" field.

func (*WorkflowCreate) SetName

func (wc *WorkflowCreate) SetName(s string) *WorkflowCreate

SetName sets the "name" field.

func (*WorkflowCreate) SetNillableCompletedTaskCount

func (wc *WorkflowCreate) SetNillableCompletedTaskCount(i *int) *WorkflowCreate

SetNillableCompletedTaskCount sets the "completed_task_count" field if the given value is not nil.

func (*WorkflowCreate) SetNillableCreatedAt

func (wc *WorkflowCreate) SetNillableCreatedAt(t *time.Time) *WorkflowCreate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*WorkflowCreate) SetNillableDurationMs

func (wc *WorkflowCreate) SetNillableDurationMs(i *int64) *WorkflowCreate

SetNillableDurationMs sets the "duration_ms" field if the given value is not nil.

func (*WorkflowCreate) SetNillableEndedAt

func (wc *WorkflowCreate) SetNillableEndedAt(t *time.Time) *WorkflowCreate

SetNillableEndedAt sets the "ended_at" field if the given value is not nil.

func (*WorkflowCreate) SetNillableErrorMessage

func (wc *WorkflowCreate) SetNillableErrorMessage(s *string) *WorkflowCreate

SetNillableErrorMessage sets the "error_message" field if the given value is not nil.

func (*WorkflowCreate) SetNillableFailedTaskCount

func (wc *WorkflowCreate) SetNillableFailedTaskCount(i *int) *WorkflowCreate

SetNillableFailedTaskCount sets the "failed_task_count" field if the given value is not nil.

func (*WorkflowCreate) SetNillableInitiator

func (wc *WorkflowCreate) SetNillableInitiator(s *string) *WorkflowCreate

SetNillableInitiator sets the "initiator" field if the given value is not nil.

func (*WorkflowCreate) SetNillableParentWorkflowID

func (wc *WorkflowCreate) SetNillableParentWorkflowID(s *string) *WorkflowCreate

SetNillableParentWorkflowID sets the "parent_workflow_id" field if the given value is not nil.

func (*WorkflowCreate) SetNillableStartedAt

func (wc *WorkflowCreate) SetNillableStartedAt(t *time.Time) *WorkflowCreate

SetNillableStartedAt sets the "started_at" field if the given value is not nil.

func (*WorkflowCreate) SetNillableStatus

func (wc *WorkflowCreate) SetNillableStatus(s *string) *WorkflowCreate

SetNillableStatus sets the "status" field if the given value is not nil.

func (*WorkflowCreate) SetNillableTaskCount

func (wc *WorkflowCreate) SetNillableTaskCount(i *int) *WorkflowCreate

SetNillableTaskCount sets the "task_count" field if the given value is not nil.

func (*WorkflowCreate) SetNillableTotalCostUsd

func (wc *WorkflowCreate) SetNillableTotalCostUsd(f *float64) *WorkflowCreate

SetNillableTotalCostUsd sets the "total_cost_usd" field if the given value is not nil.

func (*WorkflowCreate) SetNillableTotalTokens

func (wc *WorkflowCreate) SetNillableTotalTokens(i *int) *WorkflowCreate

SetNillableTotalTokens sets the "total_tokens" field if the given value is not nil.

func (*WorkflowCreate) SetNillableTraceID

func (wc *WorkflowCreate) SetNillableTraceID(s *string) *WorkflowCreate

SetNillableTraceID sets the "trace_id" field if the given value is not nil.

func (*WorkflowCreate) SetNillableUpdatedAt

func (wc *WorkflowCreate) SetNillableUpdatedAt(t *time.Time) *WorkflowCreate

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*WorkflowCreate) SetOutput

func (wc *WorkflowCreate) SetOutput(m map[string]interface{}) *WorkflowCreate

SetOutput sets the "output" field.

func (*WorkflowCreate) SetParentWorkflowID

func (wc *WorkflowCreate) SetParentWorkflowID(s string) *WorkflowCreate

SetParentWorkflowID sets the "parent_workflow_id" field.

func (*WorkflowCreate) SetStartedAt

func (wc *WorkflowCreate) SetStartedAt(t time.Time) *WorkflowCreate

SetStartedAt sets the "started_at" field.

func (*WorkflowCreate) SetStatus

func (wc *WorkflowCreate) SetStatus(s string) *WorkflowCreate

SetStatus sets the "status" field.

func (*WorkflowCreate) SetTaskCount

func (wc *WorkflowCreate) SetTaskCount(i int) *WorkflowCreate

SetTaskCount sets the "task_count" field.

func (*WorkflowCreate) SetTotalCostUsd

func (wc *WorkflowCreate) SetTotalCostUsd(f float64) *WorkflowCreate

SetTotalCostUsd sets the "total_cost_usd" field.

func (*WorkflowCreate) SetTotalTokens

func (wc *WorkflowCreate) SetTotalTokens(i int) *WorkflowCreate

SetTotalTokens sets the "total_tokens" field.

func (*WorkflowCreate) SetTraceID

func (wc *WorkflowCreate) SetTraceID(s string) *WorkflowCreate

SetTraceID sets the "trace_id" field.

func (*WorkflowCreate) SetUpdatedAt

func (wc *WorkflowCreate) SetUpdatedAt(t time.Time) *WorkflowCreate

SetUpdatedAt sets the "updated_at" field.

type WorkflowCreateBulk

type WorkflowCreateBulk struct {
	// contains filtered or unexported fields
}

WorkflowCreateBulk is the builder for creating many Workflow entities in bulk.

func (*WorkflowCreateBulk) Exec

func (wcb *WorkflowCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*WorkflowCreateBulk) ExecX

func (wcb *WorkflowCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*WorkflowCreateBulk) Save

func (wcb *WorkflowCreateBulk) Save(ctx context.Context) ([]*Workflow, error)

Save creates the Workflow entities in the database.

func (*WorkflowCreateBulk) SaveX

func (wcb *WorkflowCreateBulk) SaveX(ctx context.Context) []*Workflow

SaveX is like Save, but panics if an error occurs.

type WorkflowDelete

type WorkflowDelete struct {
	// contains filtered or unexported fields
}

WorkflowDelete is the builder for deleting a Workflow entity.

func (*WorkflowDelete) Exec

func (wd *WorkflowDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*WorkflowDelete) ExecX

func (wd *WorkflowDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*WorkflowDelete) Where

func (wd *WorkflowDelete) Where(ps ...predicate.Workflow) *WorkflowDelete

Where appends a list predicates to the WorkflowDelete builder.

type WorkflowDeleteOne

type WorkflowDeleteOne struct {
	// contains filtered or unexported fields
}

WorkflowDeleteOne is the builder for deleting a single Workflow entity.

func (*WorkflowDeleteOne) Exec

func (wdo *WorkflowDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*WorkflowDeleteOne) ExecX

func (wdo *WorkflowDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*WorkflowDeleteOne) Where

Where appends a list predicates to the WorkflowDelete builder.

type WorkflowEdges

type WorkflowEdges struct {
	// Tasks belonging to this workflow
	Tasks []*AgentTask `json:"tasks,omitempty"`
	// Agent handoffs in this workflow
	Handoffs []*AgentHandoff `json:"handoffs,omitempty"`
	// Events in this workflow
	Events []*AgentEvent `json:"events,omitempty"`
	// contains filtered or unexported fields
}

WorkflowEdges holds the relations/edges for other nodes in the graph.

func (WorkflowEdges) EventsOrErr

func (e WorkflowEdges) EventsOrErr() ([]*AgentEvent, error)

EventsOrErr returns the Events value or an error if the edge was not loaded in eager-loading.

func (WorkflowEdges) HandoffsOrErr

func (e WorkflowEdges) HandoffsOrErr() ([]*AgentHandoff, error)

HandoffsOrErr returns the Handoffs value or an error if the edge was not loaded in eager-loading.

func (WorkflowEdges) TasksOrErr

func (e WorkflowEdges) TasksOrErr() ([]*AgentTask, error)

TasksOrErr returns the Tasks value or an error if the edge was not loaded in eager-loading.

type WorkflowGroupBy

type WorkflowGroupBy struct {
	// contains filtered or unexported fields
}

WorkflowGroupBy is the group-by builder for Workflow entities.

func (*WorkflowGroupBy) Aggregate

func (wgb *WorkflowGroupBy) Aggregate(fns ...AggregateFunc) *WorkflowGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*WorkflowGroupBy) Bool

func (s *WorkflowGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*WorkflowGroupBy) BoolX

func (s *WorkflowGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*WorkflowGroupBy) Bools

func (s *WorkflowGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*WorkflowGroupBy) BoolsX

func (s *WorkflowGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*WorkflowGroupBy) Float64

func (s *WorkflowGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*WorkflowGroupBy) Float64X

func (s *WorkflowGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*WorkflowGroupBy) Float64s

func (s *WorkflowGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*WorkflowGroupBy) Float64sX

func (s *WorkflowGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*WorkflowGroupBy) Int

func (s *WorkflowGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*WorkflowGroupBy) IntX

func (s *WorkflowGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*WorkflowGroupBy) Ints

func (s *WorkflowGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*WorkflowGroupBy) IntsX

func (s *WorkflowGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*WorkflowGroupBy) Scan

func (wgb *WorkflowGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*WorkflowGroupBy) ScanX

func (s *WorkflowGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*WorkflowGroupBy) String

func (s *WorkflowGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*WorkflowGroupBy) StringX

func (s *WorkflowGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*WorkflowGroupBy) Strings

func (s *WorkflowGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*WorkflowGroupBy) StringsX

func (s *WorkflowGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type WorkflowMutation

type WorkflowMutation struct {
	// contains filtered or unexported fields
}

WorkflowMutation represents an operation that mutates the Workflow nodes in the graph.

func (*WorkflowMutation) AddCompletedTaskCount

func (m *WorkflowMutation) AddCompletedTaskCount(i int)

AddCompletedTaskCount adds i to the "completed_task_count" field.

func (*WorkflowMutation) AddDurationMs

func (m *WorkflowMutation) AddDurationMs(i int64)

AddDurationMs adds i to the "duration_ms" field.

func (*WorkflowMutation) AddEventIDs

func (m *WorkflowMutation) AddEventIDs(ids ...string)

AddEventIDs adds the "events" edge to the AgentEvent entity by ids.

func (*WorkflowMutation) AddFailedTaskCount

func (m *WorkflowMutation) AddFailedTaskCount(i int)

AddFailedTaskCount adds i to the "failed_task_count" field.

func (*WorkflowMutation) AddField

func (m *WorkflowMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*WorkflowMutation) AddHandoffIDs

func (m *WorkflowMutation) AddHandoffIDs(ids ...string)

AddHandoffIDs adds the "handoffs" edge to the AgentHandoff entity by ids.

func (*WorkflowMutation) AddTaskCount

func (m *WorkflowMutation) AddTaskCount(i int)

AddTaskCount adds i to the "task_count" field.

func (*WorkflowMutation) AddTaskIDs

func (m *WorkflowMutation) AddTaskIDs(ids ...string)

AddTaskIDs adds the "tasks" edge to the AgentTask entity by ids.

func (*WorkflowMutation) AddTotalCostUsd

func (m *WorkflowMutation) AddTotalCostUsd(f float64)

AddTotalCostUsd adds f to the "total_cost_usd" field.

func (*WorkflowMutation) AddTotalTokens

func (m *WorkflowMutation) AddTotalTokens(i int)

AddTotalTokens adds i to the "total_tokens" field.

func (*WorkflowMutation) AddedCompletedTaskCount

func (m *WorkflowMutation) AddedCompletedTaskCount() (r int, exists bool)

AddedCompletedTaskCount returns the value that was added to the "completed_task_count" field in this mutation.

func (*WorkflowMutation) AddedDurationMs

func (m *WorkflowMutation) AddedDurationMs() (r int64, exists bool)

AddedDurationMs returns the value that was added to the "duration_ms" field in this mutation.

func (*WorkflowMutation) AddedEdges

func (m *WorkflowMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*WorkflowMutation) AddedFailedTaskCount

func (m *WorkflowMutation) AddedFailedTaskCount() (r int, exists bool)

AddedFailedTaskCount returns the value that was added to the "failed_task_count" field in this mutation.

func (*WorkflowMutation) AddedField

func (m *WorkflowMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*WorkflowMutation) AddedFields

func (m *WorkflowMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*WorkflowMutation) AddedIDs

func (m *WorkflowMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*WorkflowMutation) AddedTaskCount

func (m *WorkflowMutation) AddedTaskCount() (r int, exists bool)

AddedTaskCount returns the value that was added to the "task_count" field in this mutation.

func (*WorkflowMutation) AddedTotalCostUsd

func (m *WorkflowMutation) AddedTotalCostUsd() (r float64, exists bool)

AddedTotalCostUsd returns the value that was added to the "total_cost_usd" field in this mutation.

func (*WorkflowMutation) AddedTotalTokens

func (m *WorkflowMutation) AddedTotalTokens() (r int, exists bool)

AddedTotalTokens returns the value that was added to the "total_tokens" field in this mutation.

func (*WorkflowMutation) ClearDurationMs

func (m *WorkflowMutation) ClearDurationMs()

ClearDurationMs clears the value of the "duration_ms" field.

func (*WorkflowMutation) ClearEdge

func (m *WorkflowMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*WorkflowMutation) ClearEndedAt

func (m *WorkflowMutation) ClearEndedAt()

ClearEndedAt clears the value of the "ended_at" field.

func (*WorkflowMutation) ClearErrorMessage

func (m *WorkflowMutation) ClearErrorMessage()

ClearErrorMessage clears the value of the "error_message" field.

func (*WorkflowMutation) ClearEvents

func (m *WorkflowMutation) ClearEvents()

ClearEvents clears the "events" edge to the AgentEvent entity.

func (*WorkflowMutation) ClearField

func (m *WorkflowMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*WorkflowMutation) ClearHandoffs

func (m *WorkflowMutation) ClearHandoffs()

ClearHandoffs clears the "handoffs" edge to the AgentHandoff entity.

func (*WorkflowMutation) ClearInitiator

func (m *WorkflowMutation) ClearInitiator()

ClearInitiator clears the value of the "initiator" field.

func (*WorkflowMutation) ClearInput

func (m *WorkflowMutation) ClearInput()

ClearInput clears the value of the "input" field.

func (*WorkflowMutation) ClearMetadata

func (m *WorkflowMutation) ClearMetadata()

ClearMetadata clears the value of the "metadata" field.

func (*WorkflowMutation) ClearOutput

func (m *WorkflowMutation) ClearOutput()

ClearOutput clears the value of the "output" field.

func (*WorkflowMutation) ClearParentWorkflowID

func (m *WorkflowMutation) ClearParentWorkflowID()

ClearParentWorkflowID clears the value of the "parent_workflow_id" field.

func (*WorkflowMutation) ClearTasks

func (m *WorkflowMutation) ClearTasks()

ClearTasks clears the "tasks" edge to the AgentTask entity.

func (*WorkflowMutation) ClearTraceID

func (m *WorkflowMutation) ClearTraceID()

ClearTraceID clears the value of the "trace_id" field.

func (*WorkflowMutation) ClearedEdges

func (m *WorkflowMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*WorkflowMutation) ClearedFields

func (m *WorkflowMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (WorkflowMutation) Client

func (m WorkflowMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*WorkflowMutation) CompletedTaskCount

func (m *WorkflowMutation) CompletedTaskCount() (r int, exists bool)

CompletedTaskCount returns the value of the "completed_task_count" field in the mutation.

func (*WorkflowMutation) CreatedAt

func (m *WorkflowMutation) CreatedAt() (r time.Time, exists bool)

CreatedAt returns the value of the "created_at" field in the mutation.

func (*WorkflowMutation) DurationMs

func (m *WorkflowMutation) DurationMs() (r int64, exists bool)

DurationMs returns the value of the "duration_ms" field in the mutation.

func (*WorkflowMutation) DurationMsCleared

func (m *WorkflowMutation) DurationMsCleared() bool

DurationMsCleared returns if the "duration_ms" field was cleared in this mutation.

func (*WorkflowMutation) EdgeCleared

func (m *WorkflowMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*WorkflowMutation) EndedAt

func (m *WorkflowMutation) EndedAt() (r time.Time, exists bool)

EndedAt returns the value of the "ended_at" field in the mutation.

func (*WorkflowMutation) EndedAtCleared

func (m *WorkflowMutation) EndedAtCleared() bool

EndedAtCleared returns if the "ended_at" field was cleared in this mutation.

func (*WorkflowMutation) ErrorMessage

func (m *WorkflowMutation) ErrorMessage() (r string, exists bool)

ErrorMessage returns the value of the "error_message" field in the mutation.

func (*WorkflowMutation) ErrorMessageCleared

func (m *WorkflowMutation) ErrorMessageCleared() bool

ErrorMessageCleared returns if the "error_message" field was cleared in this mutation.

func (*WorkflowMutation) EventsCleared

func (m *WorkflowMutation) EventsCleared() bool

EventsCleared reports if the "events" edge to the AgentEvent entity was cleared.

func (*WorkflowMutation) EventsIDs

func (m *WorkflowMutation) EventsIDs() (ids []string)

EventsIDs returns the "events" edge IDs in the mutation.

func (*WorkflowMutation) FailedTaskCount

func (m *WorkflowMutation) FailedTaskCount() (r int, exists bool)

FailedTaskCount returns the value of the "failed_task_count" field in the mutation.

func (*WorkflowMutation) Field

func (m *WorkflowMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*WorkflowMutation) FieldCleared

func (m *WorkflowMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*WorkflowMutation) Fields

func (m *WorkflowMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*WorkflowMutation) HandoffsCleared

func (m *WorkflowMutation) HandoffsCleared() bool

HandoffsCleared reports if the "handoffs" edge to the AgentHandoff entity was cleared.

func (*WorkflowMutation) HandoffsIDs

func (m *WorkflowMutation) HandoffsIDs() (ids []string)

HandoffsIDs returns the "handoffs" edge IDs in the mutation.

func (*WorkflowMutation) ID

func (m *WorkflowMutation) ID() (id string, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*WorkflowMutation) IDs

func (m *WorkflowMutation) IDs(ctx context.Context) ([]string, error)

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*WorkflowMutation) Initiator

func (m *WorkflowMutation) Initiator() (r string, exists bool)

Initiator returns the value of the "initiator" field in the mutation.

func (*WorkflowMutation) InitiatorCleared

func (m *WorkflowMutation) InitiatorCleared() bool

InitiatorCleared returns if the "initiator" field was cleared in this mutation.

func (*WorkflowMutation) Input

func (m *WorkflowMutation) Input() (r map[string]interface{}, exists bool)

Input returns the value of the "input" field in the mutation.

func (*WorkflowMutation) InputCleared

func (m *WorkflowMutation) InputCleared() bool

InputCleared returns if the "input" field was cleared in this mutation.

func (*WorkflowMutation) Metadata

func (m *WorkflowMutation) Metadata() (r map[string]interface{}, exists bool)

Metadata returns the value of the "metadata" field in the mutation.

func (*WorkflowMutation) MetadataCleared

func (m *WorkflowMutation) MetadataCleared() bool

MetadataCleared returns if the "metadata" field was cleared in this mutation.

func (*WorkflowMutation) Name

func (m *WorkflowMutation) Name() (r string, exists bool)

Name returns the value of the "name" field in the mutation.

func (*WorkflowMutation) OldCompletedTaskCount

func (m *WorkflowMutation) OldCompletedTaskCount(ctx context.Context) (v int, err error)

OldCompletedTaskCount returns the old "completed_task_count" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) OldCreatedAt

func (m *WorkflowMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)

OldCreatedAt returns the old "created_at" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) OldDurationMs

func (m *WorkflowMutation) OldDurationMs(ctx context.Context) (v int64, err error)

OldDurationMs returns the old "duration_ms" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) OldEndedAt

func (m *WorkflowMutation) OldEndedAt(ctx context.Context) (v *time.Time, err error)

OldEndedAt returns the old "ended_at" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) OldErrorMessage

func (m *WorkflowMutation) OldErrorMessage(ctx context.Context) (v string, err error)

OldErrorMessage returns the old "error_message" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) OldFailedTaskCount

func (m *WorkflowMutation) OldFailedTaskCount(ctx context.Context) (v int, err error)

OldFailedTaskCount returns the old "failed_task_count" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) OldField

func (m *WorkflowMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*WorkflowMutation) OldInitiator

func (m *WorkflowMutation) OldInitiator(ctx context.Context) (v string, err error)

OldInitiator returns the old "initiator" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) OldInput

func (m *WorkflowMutation) OldInput(ctx context.Context) (v map[string]interface{}, err error)

OldInput returns the old "input" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) OldMetadata

func (m *WorkflowMutation) OldMetadata(ctx context.Context) (v map[string]interface{}, err error)

OldMetadata returns the old "metadata" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) OldName

func (m *WorkflowMutation) OldName(ctx context.Context) (v string, err error)

OldName returns the old "name" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) OldOutput

func (m *WorkflowMutation) OldOutput(ctx context.Context) (v map[string]interface{}, err error)

OldOutput returns the old "output" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) OldParentWorkflowID

func (m *WorkflowMutation) OldParentWorkflowID(ctx context.Context) (v string, err error)

OldParentWorkflowID returns the old "parent_workflow_id" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) OldStartedAt

func (m *WorkflowMutation) OldStartedAt(ctx context.Context) (v time.Time, err error)

OldStartedAt returns the old "started_at" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) OldStatus

func (m *WorkflowMutation) OldStatus(ctx context.Context) (v string, err error)

OldStatus returns the old "status" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) OldTaskCount

func (m *WorkflowMutation) OldTaskCount(ctx context.Context) (v int, err error)

OldTaskCount returns the old "task_count" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) OldTotalCostUsd

func (m *WorkflowMutation) OldTotalCostUsd(ctx context.Context) (v float64, err error)

OldTotalCostUsd returns the old "total_cost_usd" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) OldTotalTokens

func (m *WorkflowMutation) OldTotalTokens(ctx context.Context) (v int, err error)

OldTotalTokens returns the old "total_tokens" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) OldTraceID

func (m *WorkflowMutation) OldTraceID(ctx context.Context) (v string, err error)

OldTraceID returns the old "trace_id" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) OldUpdatedAt

func (m *WorkflowMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)

OldUpdatedAt returns the old "updated_at" field's value of the Workflow entity. If the Workflow object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*WorkflowMutation) Op

func (m *WorkflowMutation) Op() Op

Op returns the operation name.

func (*WorkflowMutation) Output

func (m *WorkflowMutation) Output() (r map[string]interface{}, exists bool)

Output returns the value of the "output" field in the mutation.

func (*WorkflowMutation) OutputCleared

func (m *WorkflowMutation) OutputCleared() bool

OutputCleared returns if the "output" field was cleared in this mutation.

func (*WorkflowMutation) ParentWorkflowID

func (m *WorkflowMutation) ParentWorkflowID() (r string, exists bool)

ParentWorkflowID returns the value of the "parent_workflow_id" field in the mutation.

func (*WorkflowMutation) ParentWorkflowIDCleared

func (m *WorkflowMutation) ParentWorkflowIDCleared() bool

ParentWorkflowIDCleared returns if the "parent_workflow_id" field was cleared in this mutation.

func (*WorkflowMutation) RemoveEventIDs

func (m *WorkflowMutation) RemoveEventIDs(ids ...string)

RemoveEventIDs removes the "events" edge to the AgentEvent entity by IDs.

func (*WorkflowMutation) RemoveHandoffIDs

func (m *WorkflowMutation) RemoveHandoffIDs(ids ...string)

RemoveHandoffIDs removes the "handoffs" edge to the AgentHandoff entity by IDs.

func (*WorkflowMutation) RemoveTaskIDs

func (m *WorkflowMutation) RemoveTaskIDs(ids ...string)

RemoveTaskIDs removes the "tasks" edge to the AgentTask entity by IDs.

func (*WorkflowMutation) RemovedEdges

func (m *WorkflowMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*WorkflowMutation) RemovedEventsIDs

func (m *WorkflowMutation) RemovedEventsIDs() (ids []string)

RemovedEvents returns the removed IDs of the "events" edge to the AgentEvent entity.

func (*WorkflowMutation) RemovedHandoffsIDs

func (m *WorkflowMutation) RemovedHandoffsIDs() (ids []string)

RemovedHandoffs returns the removed IDs of the "handoffs" edge to the AgentHandoff entity.

func (*WorkflowMutation) RemovedIDs

func (m *WorkflowMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*WorkflowMutation) RemovedTasksIDs

func (m *WorkflowMutation) RemovedTasksIDs() (ids []string)

RemovedTasks returns the removed IDs of the "tasks" edge to the AgentTask entity.

func (*WorkflowMutation) ResetCompletedTaskCount

func (m *WorkflowMutation) ResetCompletedTaskCount()

ResetCompletedTaskCount resets all changes to the "completed_task_count" field.

func (*WorkflowMutation) ResetCreatedAt

func (m *WorkflowMutation) ResetCreatedAt()

ResetCreatedAt resets all changes to the "created_at" field.

func (*WorkflowMutation) ResetDurationMs

func (m *WorkflowMutation) ResetDurationMs()

ResetDurationMs resets all changes to the "duration_ms" field.

func (*WorkflowMutation) ResetEdge

func (m *WorkflowMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*WorkflowMutation) ResetEndedAt

func (m *WorkflowMutation) ResetEndedAt()

ResetEndedAt resets all changes to the "ended_at" field.

func (*WorkflowMutation) ResetErrorMessage

func (m *WorkflowMutation) ResetErrorMessage()

ResetErrorMessage resets all changes to the "error_message" field.

func (*WorkflowMutation) ResetEvents

func (m *WorkflowMutation) ResetEvents()

ResetEvents resets all changes to the "events" edge.

func (*WorkflowMutation) ResetFailedTaskCount

func (m *WorkflowMutation) ResetFailedTaskCount()

ResetFailedTaskCount resets all changes to the "failed_task_count" field.

func (*WorkflowMutation) ResetField

func (m *WorkflowMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*WorkflowMutation) ResetHandoffs

func (m *WorkflowMutation) ResetHandoffs()

ResetHandoffs resets all changes to the "handoffs" edge.

func (*WorkflowMutation) ResetInitiator

func (m *WorkflowMutation) ResetInitiator()

ResetInitiator resets all changes to the "initiator" field.

func (*WorkflowMutation) ResetInput

func (m *WorkflowMutation) ResetInput()

ResetInput resets all changes to the "input" field.

func (*WorkflowMutation) ResetMetadata

func (m *WorkflowMutation) ResetMetadata()

ResetMetadata resets all changes to the "metadata" field.

func (*WorkflowMutation) ResetName

func (m *WorkflowMutation) ResetName()

ResetName resets all changes to the "name" field.

func (*WorkflowMutation) ResetOutput

func (m *WorkflowMutation) ResetOutput()

ResetOutput resets all changes to the "output" field.

func (*WorkflowMutation) ResetParentWorkflowID

func (m *WorkflowMutation) ResetParentWorkflowID()

ResetParentWorkflowID resets all changes to the "parent_workflow_id" field.

func (*WorkflowMutation) ResetStartedAt

func (m *WorkflowMutation) ResetStartedAt()

ResetStartedAt resets all changes to the "started_at" field.

func (*WorkflowMutation) ResetStatus

func (m *WorkflowMutation) ResetStatus()

ResetStatus resets all changes to the "status" field.

func (*WorkflowMutation) ResetTaskCount

func (m *WorkflowMutation) ResetTaskCount()

ResetTaskCount resets all changes to the "task_count" field.

func (*WorkflowMutation) ResetTasks

func (m *WorkflowMutation) ResetTasks()

ResetTasks resets all changes to the "tasks" edge.

func (*WorkflowMutation) ResetTotalCostUsd

func (m *WorkflowMutation) ResetTotalCostUsd()

ResetTotalCostUsd resets all changes to the "total_cost_usd" field.

func (*WorkflowMutation) ResetTotalTokens

func (m *WorkflowMutation) ResetTotalTokens()

ResetTotalTokens resets all changes to the "total_tokens" field.

func (*WorkflowMutation) ResetTraceID

func (m *WorkflowMutation) ResetTraceID()

ResetTraceID resets all changes to the "trace_id" field.

func (*WorkflowMutation) ResetUpdatedAt

func (m *WorkflowMutation) ResetUpdatedAt()

ResetUpdatedAt resets all changes to the "updated_at" field.

func (*WorkflowMutation) SetCompletedTaskCount

func (m *WorkflowMutation) SetCompletedTaskCount(i int)

SetCompletedTaskCount sets the "completed_task_count" field.

func (*WorkflowMutation) SetCreatedAt

func (m *WorkflowMutation) SetCreatedAt(t time.Time)

SetCreatedAt sets the "created_at" field.

func (*WorkflowMutation) SetDurationMs

func (m *WorkflowMutation) SetDurationMs(i int64)

SetDurationMs sets the "duration_ms" field.

func (*WorkflowMutation) SetEndedAt

func (m *WorkflowMutation) SetEndedAt(t time.Time)

SetEndedAt sets the "ended_at" field.

func (*WorkflowMutation) SetErrorMessage

func (m *WorkflowMutation) SetErrorMessage(s string)

SetErrorMessage sets the "error_message" field.

func (*WorkflowMutation) SetFailedTaskCount

func (m *WorkflowMutation) SetFailedTaskCount(i int)

SetFailedTaskCount sets the "failed_task_count" field.

func (*WorkflowMutation) SetField

func (m *WorkflowMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*WorkflowMutation) SetID

func (m *WorkflowMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of Workflow entities.

func (*WorkflowMutation) SetInitiator

func (m *WorkflowMutation) SetInitiator(s string)

SetInitiator sets the "initiator" field.

func (*WorkflowMutation) SetInput

func (m *WorkflowMutation) SetInput(value map[string]interface{})

SetInput sets the "input" field.

func (*WorkflowMutation) SetMetadata

func (m *WorkflowMutation) SetMetadata(value map[string]interface{})

SetMetadata sets the "metadata" field.

func (*WorkflowMutation) SetName

func (m *WorkflowMutation) SetName(s string)

SetName sets the "name" field.

func (*WorkflowMutation) SetOp

func (m *WorkflowMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*WorkflowMutation) SetOutput

func (m *WorkflowMutation) SetOutput(value map[string]interface{})

SetOutput sets the "output" field.

func (*WorkflowMutation) SetParentWorkflowID

func (m *WorkflowMutation) SetParentWorkflowID(s string)

SetParentWorkflowID sets the "parent_workflow_id" field.

func (*WorkflowMutation) SetStartedAt

func (m *WorkflowMutation) SetStartedAt(t time.Time)

SetStartedAt sets the "started_at" field.

func (*WorkflowMutation) SetStatus

func (m *WorkflowMutation) SetStatus(s string)

SetStatus sets the "status" field.

func (*WorkflowMutation) SetTaskCount

func (m *WorkflowMutation) SetTaskCount(i int)

SetTaskCount sets the "task_count" field.

func (*WorkflowMutation) SetTotalCostUsd

func (m *WorkflowMutation) SetTotalCostUsd(f float64)

SetTotalCostUsd sets the "total_cost_usd" field.

func (*WorkflowMutation) SetTotalTokens

func (m *WorkflowMutation) SetTotalTokens(i int)

SetTotalTokens sets the "total_tokens" field.

func (*WorkflowMutation) SetTraceID

func (m *WorkflowMutation) SetTraceID(s string)

SetTraceID sets the "trace_id" field.

func (*WorkflowMutation) SetUpdatedAt

func (m *WorkflowMutation) SetUpdatedAt(t time.Time)

SetUpdatedAt sets the "updated_at" field.

func (*WorkflowMutation) StartedAt

func (m *WorkflowMutation) StartedAt() (r time.Time, exists bool)

StartedAt returns the value of the "started_at" field in the mutation.

func (*WorkflowMutation) Status

func (m *WorkflowMutation) Status() (r string, exists bool)

Status returns the value of the "status" field in the mutation.

func (*WorkflowMutation) TaskCount

func (m *WorkflowMutation) TaskCount() (r int, exists bool)

TaskCount returns the value of the "task_count" field in the mutation.

func (*WorkflowMutation) TasksCleared

func (m *WorkflowMutation) TasksCleared() bool

TasksCleared reports if the "tasks" edge to the AgentTask entity was cleared.

func (*WorkflowMutation) TasksIDs

func (m *WorkflowMutation) TasksIDs() (ids []string)

TasksIDs returns the "tasks" edge IDs in the mutation.

func (*WorkflowMutation) TotalCostUsd

func (m *WorkflowMutation) TotalCostUsd() (r float64, exists bool)

TotalCostUsd returns the value of the "total_cost_usd" field in the mutation.

func (*WorkflowMutation) TotalTokens

func (m *WorkflowMutation) TotalTokens() (r int, exists bool)

TotalTokens returns the value of the "total_tokens" field in the mutation.

func (*WorkflowMutation) TraceID

func (m *WorkflowMutation) TraceID() (r string, exists bool)

TraceID returns the value of the "trace_id" field in the mutation.

func (*WorkflowMutation) TraceIDCleared

func (m *WorkflowMutation) TraceIDCleared() bool

TraceIDCleared returns if the "trace_id" field was cleared in this mutation.

func (WorkflowMutation) Tx

func (m WorkflowMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*WorkflowMutation) Type

func (m *WorkflowMutation) Type() string

Type returns the node type of this mutation (Workflow).

func (*WorkflowMutation) UpdatedAt

func (m *WorkflowMutation) UpdatedAt() (r time.Time, exists bool)

UpdatedAt returns the value of the "updated_at" field in the mutation.

func (*WorkflowMutation) Where

func (m *WorkflowMutation) Where(ps ...predicate.Workflow)

Where appends a list predicates to the WorkflowMutation builder.

func (*WorkflowMutation) WhereP

func (m *WorkflowMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the WorkflowMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type WorkflowQuery

type WorkflowQuery struct {
	// contains filtered or unexported fields
}

WorkflowQuery is the builder for querying Workflow entities.

func (*WorkflowQuery) Aggregate

func (wq *WorkflowQuery) Aggregate(fns ...AggregateFunc) *WorkflowSelect

Aggregate returns a WorkflowSelect configured with the given aggregations.

func (*WorkflowQuery) All

func (wq *WorkflowQuery) All(ctx context.Context) ([]*Workflow, error)

All executes the query and returns a list of Workflows.

func (*WorkflowQuery) AllX

func (wq *WorkflowQuery) AllX(ctx context.Context) []*Workflow

AllX is like All, but panics if an error occurs.

func (*WorkflowQuery) Clone

func (wq *WorkflowQuery) Clone() *WorkflowQuery

Clone returns a duplicate of the WorkflowQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*WorkflowQuery) Count

func (wq *WorkflowQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*WorkflowQuery) CountX

func (wq *WorkflowQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*WorkflowQuery) Exist

func (wq *WorkflowQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*WorkflowQuery) ExistX

func (wq *WorkflowQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*WorkflowQuery) First

func (wq *WorkflowQuery) First(ctx context.Context) (*Workflow, error)

First returns the first Workflow entity from the query. Returns a *NotFoundError when no Workflow was found.

func (*WorkflowQuery) FirstID

func (wq *WorkflowQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first Workflow ID from the query. Returns a *NotFoundError when no Workflow ID was found.

func (*WorkflowQuery) FirstIDX

func (wq *WorkflowQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*WorkflowQuery) FirstX

func (wq *WorkflowQuery) FirstX(ctx context.Context) *Workflow

FirstX is like First, but panics if an error occurs.

func (*WorkflowQuery) GroupBy

func (wq *WorkflowQuery) GroupBy(field string, fields ...string) *WorkflowGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Name string `json:"name,omitempty"`
	Count int `json:"count,omitempty"`
}

client.Workflow.Query().
	GroupBy(workflow.FieldName).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*WorkflowQuery) IDs

func (wq *WorkflowQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of Workflow IDs.

func (*WorkflowQuery) IDsX

func (wq *WorkflowQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*WorkflowQuery) Limit

func (wq *WorkflowQuery) Limit(limit int) *WorkflowQuery

Limit the number of records to be returned by this query.

func (*WorkflowQuery) Offset

func (wq *WorkflowQuery) Offset(offset int) *WorkflowQuery

Offset to start from.

func (*WorkflowQuery) Only

func (wq *WorkflowQuery) Only(ctx context.Context) (*Workflow, error)

Only returns a single Workflow entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Workflow entity is found. Returns a *NotFoundError when no Workflow entities are found.

func (*WorkflowQuery) OnlyID

func (wq *WorkflowQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only Workflow ID in the query. Returns a *NotSingularError when more than one Workflow ID is found. Returns a *NotFoundError when no entities are found.

func (*WorkflowQuery) OnlyIDX

func (wq *WorkflowQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*WorkflowQuery) OnlyX

func (wq *WorkflowQuery) OnlyX(ctx context.Context) *Workflow

OnlyX is like Only, but panics if an error occurs.

func (*WorkflowQuery) Order

Order specifies how the records should be ordered.

func (*WorkflowQuery) QueryEvents

func (wq *WorkflowQuery) QueryEvents() *AgentEventQuery

QueryEvents chains the current query on the "events" edge.

func (*WorkflowQuery) QueryHandoffs

func (wq *WorkflowQuery) QueryHandoffs() *AgentHandoffQuery

QueryHandoffs chains the current query on the "handoffs" edge.

func (*WorkflowQuery) QueryTasks

func (wq *WorkflowQuery) QueryTasks() *AgentTaskQuery

QueryTasks chains the current query on the "tasks" edge.

func (*WorkflowQuery) Select

func (wq *WorkflowQuery) Select(fields ...string) *WorkflowSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Name string `json:"name,omitempty"`
}

client.Workflow.Query().
	Select(workflow.FieldName).
	Scan(ctx, &v)

func (*WorkflowQuery) Unique

func (wq *WorkflowQuery) Unique(unique bool) *WorkflowQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*WorkflowQuery) Where

func (wq *WorkflowQuery) Where(ps ...predicate.Workflow) *WorkflowQuery

Where adds a new predicate for the WorkflowQuery builder.

func (*WorkflowQuery) WithEvents

func (wq *WorkflowQuery) WithEvents(opts ...func(*AgentEventQuery)) *WorkflowQuery

WithEvents tells the query-builder to eager-load the nodes that are connected to the "events" edge. The optional arguments are used to configure the query builder of the edge.

func (*WorkflowQuery) WithHandoffs

func (wq *WorkflowQuery) WithHandoffs(opts ...func(*AgentHandoffQuery)) *WorkflowQuery

WithHandoffs tells the query-builder to eager-load the nodes that are connected to the "handoffs" edge. The optional arguments are used to configure the query builder of the edge.

func (*WorkflowQuery) WithTasks

func (wq *WorkflowQuery) WithTasks(opts ...func(*AgentTaskQuery)) *WorkflowQuery

WithTasks tells the query-builder to eager-load the nodes that are connected to the "tasks" edge. The optional arguments are used to configure the query builder of the edge.

type WorkflowSelect

type WorkflowSelect struct {
	*WorkflowQuery
	// contains filtered or unexported fields
}

WorkflowSelect is the builder for selecting fields of Workflow entities.

func (*WorkflowSelect) Aggregate

func (ws *WorkflowSelect) Aggregate(fns ...AggregateFunc) *WorkflowSelect

Aggregate adds the given aggregation functions to the selector query.

func (*WorkflowSelect) Bool

func (s *WorkflowSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*WorkflowSelect) BoolX

func (s *WorkflowSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*WorkflowSelect) Bools

func (s *WorkflowSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*WorkflowSelect) BoolsX

func (s *WorkflowSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*WorkflowSelect) Float64

func (s *WorkflowSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*WorkflowSelect) Float64X

func (s *WorkflowSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*WorkflowSelect) Float64s

func (s *WorkflowSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*WorkflowSelect) Float64sX

func (s *WorkflowSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*WorkflowSelect) Int

func (s *WorkflowSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*WorkflowSelect) IntX

func (s *WorkflowSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*WorkflowSelect) Ints

func (s *WorkflowSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*WorkflowSelect) IntsX

func (s *WorkflowSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*WorkflowSelect) Scan

func (ws *WorkflowSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*WorkflowSelect) ScanX

func (s *WorkflowSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*WorkflowSelect) String

func (s *WorkflowSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*WorkflowSelect) StringX

func (s *WorkflowSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*WorkflowSelect) Strings

func (s *WorkflowSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*WorkflowSelect) StringsX

func (s *WorkflowSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type WorkflowUpdate

type WorkflowUpdate struct {
	// contains filtered or unexported fields
}

WorkflowUpdate is the builder for updating Workflow entities.

func (*WorkflowUpdate) AddCompletedTaskCount

func (wu *WorkflowUpdate) AddCompletedTaskCount(i int) *WorkflowUpdate

AddCompletedTaskCount adds i to the "completed_task_count" field.

func (*WorkflowUpdate) AddDurationMs

func (wu *WorkflowUpdate) AddDurationMs(i int64) *WorkflowUpdate

AddDurationMs adds i to the "duration_ms" field.

func (*WorkflowUpdate) AddEventIDs

func (wu *WorkflowUpdate) AddEventIDs(ids ...string) *WorkflowUpdate

AddEventIDs adds the "events" edge to the AgentEvent entity by IDs.

func (*WorkflowUpdate) AddEvents

func (wu *WorkflowUpdate) AddEvents(a ...*AgentEvent) *WorkflowUpdate

AddEvents adds the "events" edges to the AgentEvent entity.

func (*WorkflowUpdate) AddFailedTaskCount

func (wu *WorkflowUpdate) AddFailedTaskCount(i int) *WorkflowUpdate

AddFailedTaskCount adds i to the "failed_task_count" field.

func (*WorkflowUpdate) AddHandoffIDs

func (wu *WorkflowUpdate) AddHandoffIDs(ids ...string) *WorkflowUpdate

AddHandoffIDs adds the "handoffs" edge to the AgentHandoff entity by IDs.

func (*WorkflowUpdate) AddHandoffs

func (wu *WorkflowUpdate) AddHandoffs(a ...*AgentHandoff) *WorkflowUpdate

AddHandoffs adds the "handoffs" edges to the AgentHandoff entity.

func (*WorkflowUpdate) AddTaskCount

func (wu *WorkflowUpdate) AddTaskCount(i int) *WorkflowUpdate

AddTaskCount adds i to the "task_count" field.

func (*WorkflowUpdate) AddTaskIDs

func (wu *WorkflowUpdate) AddTaskIDs(ids ...string) *WorkflowUpdate

AddTaskIDs adds the "tasks" edge to the AgentTask entity by IDs.

func (*WorkflowUpdate) AddTasks

func (wu *WorkflowUpdate) AddTasks(a ...*AgentTask) *WorkflowUpdate

AddTasks adds the "tasks" edges to the AgentTask entity.

func (*WorkflowUpdate) AddTotalCostUsd

func (wu *WorkflowUpdate) AddTotalCostUsd(f float64) *WorkflowUpdate

AddTotalCostUsd adds f to the "total_cost_usd" field.

func (*WorkflowUpdate) AddTotalTokens

func (wu *WorkflowUpdate) AddTotalTokens(i int) *WorkflowUpdate

AddTotalTokens adds i to the "total_tokens" field.

func (*WorkflowUpdate) ClearDurationMs

func (wu *WorkflowUpdate) ClearDurationMs() *WorkflowUpdate

ClearDurationMs clears the value of the "duration_ms" field.

func (*WorkflowUpdate) ClearEndedAt

func (wu *WorkflowUpdate) ClearEndedAt() *WorkflowUpdate

ClearEndedAt clears the value of the "ended_at" field.

func (*WorkflowUpdate) ClearErrorMessage

func (wu *WorkflowUpdate) ClearErrorMessage() *WorkflowUpdate

ClearErrorMessage clears the value of the "error_message" field.

func (*WorkflowUpdate) ClearEvents

func (wu *WorkflowUpdate) ClearEvents() *WorkflowUpdate

ClearEvents clears all "events" edges to the AgentEvent entity.

func (*WorkflowUpdate) ClearHandoffs

func (wu *WorkflowUpdate) ClearHandoffs() *WorkflowUpdate

ClearHandoffs clears all "handoffs" edges to the AgentHandoff entity.

func (*WorkflowUpdate) ClearInitiator

func (wu *WorkflowUpdate) ClearInitiator() *WorkflowUpdate

ClearInitiator clears the value of the "initiator" field.

func (*WorkflowUpdate) ClearInput

func (wu *WorkflowUpdate) ClearInput() *WorkflowUpdate

ClearInput clears the value of the "input" field.

func (*WorkflowUpdate) ClearMetadata

func (wu *WorkflowUpdate) ClearMetadata() *WorkflowUpdate

ClearMetadata clears the value of the "metadata" field.

func (*WorkflowUpdate) ClearOutput

func (wu *WorkflowUpdate) ClearOutput() *WorkflowUpdate

ClearOutput clears the value of the "output" field.

func (*WorkflowUpdate) ClearParentWorkflowID

func (wu *WorkflowUpdate) ClearParentWorkflowID() *WorkflowUpdate

ClearParentWorkflowID clears the value of the "parent_workflow_id" field.

func (*WorkflowUpdate) ClearTasks

func (wu *WorkflowUpdate) ClearTasks() *WorkflowUpdate

ClearTasks clears all "tasks" edges to the AgentTask entity.

func (*WorkflowUpdate) ClearTraceID

func (wu *WorkflowUpdate) ClearTraceID() *WorkflowUpdate

ClearTraceID clears the value of the "trace_id" field.

func (*WorkflowUpdate) Exec

func (wu *WorkflowUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*WorkflowUpdate) ExecX

func (wu *WorkflowUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*WorkflowUpdate) Mutation

func (wu *WorkflowUpdate) Mutation() *WorkflowMutation

Mutation returns the WorkflowMutation object of the builder.

func (*WorkflowUpdate) RemoveEventIDs

func (wu *WorkflowUpdate) RemoveEventIDs(ids ...string) *WorkflowUpdate

RemoveEventIDs removes the "events" edge to AgentEvent entities by IDs.

func (*WorkflowUpdate) RemoveEvents

func (wu *WorkflowUpdate) RemoveEvents(a ...*AgentEvent) *WorkflowUpdate

RemoveEvents removes "events" edges to AgentEvent entities.

func (*WorkflowUpdate) RemoveHandoffIDs

func (wu *WorkflowUpdate) RemoveHandoffIDs(ids ...string) *WorkflowUpdate

RemoveHandoffIDs removes the "handoffs" edge to AgentHandoff entities by IDs.

func (*WorkflowUpdate) RemoveHandoffs

func (wu *WorkflowUpdate) RemoveHandoffs(a ...*AgentHandoff) *WorkflowUpdate

RemoveHandoffs removes "handoffs" edges to AgentHandoff entities.

func (*WorkflowUpdate) RemoveTaskIDs

func (wu *WorkflowUpdate) RemoveTaskIDs(ids ...string) *WorkflowUpdate

RemoveTaskIDs removes the "tasks" edge to AgentTask entities by IDs.

func (*WorkflowUpdate) RemoveTasks

func (wu *WorkflowUpdate) RemoveTasks(a ...*AgentTask) *WorkflowUpdate

RemoveTasks removes "tasks" edges to AgentTask entities.

func (*WorkflowUpdate) Save

func (wu *WorkflowUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*WorkflowUpdate) SaveX

func (wu *WorkflowUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*WorkflowUpdate) SetCompletedTaskCount

func (wu *WorkflowUpdate) SetCompletedTaskCount(i int) *WorkflowUpdate

SetCompletedTaskCount sets the "completed_task_count" field.

func (*WorkflowUpdate) SetDurationMs

func (wu *WorkflowUpdate) SetDurationMs(i int64) *WorkflowUpdate

SetDurationMs sets the "duration_ms" field.

func (*WorkflowUpdate) SetEndedAt

func (wu *WorkflowUpdate) SetEndedAt(t time.Time) *WorkflowUpdate

SetEndedAt sets the "ended_at" field.

func (*WorkflowUpdate) SetErrorMessage

func (wu *WorkflowUpdate) SetErrorMessage(s string) *WorkflowUpdate

SetErrorMessage sets the "error_message" field.

func (*WorkflowUpdate) SetFailedTaskCount

func (wu *WorkflowUpdate) SetFailedTaskCount(i int) *WorkflowUpdate

SetFailedTaskCount sets the "failed_task_count" field.

func (*WorkflowUpdate) SetInitiator

func (wu *WorkflowUpdate) SetInitiator(s string) *WorkflowUpdate

SetInitiator sets the "initiator" field.

func (*WorkflowUpdate) SetInput

func (wu *WorkflowUpdate) SetInput(m map[string]interface{}) *WorkflowUpdate

SetInput sets the "input" field.

func (*WorkflowUpdate) SetMetadata

func (wu *WorkflowUpdate) SetMetadata(m map[string]interface{}) *WorkflowUpdate

SetMetadata sets the "metadata" field.

func (*WorkflowUpdate) SetName

func (wu *WorkflowUpdate) SetName(s string) *WorkflowUpdate

SetName sets the "name" field.

func (*WorkflowUpdate) SetNillableCompletedTaskCount

func (wu *WorkflowUpdate) SetNillableCompletedTaskCount(i *int) *WorkflowUpdate

SetNillableCompletedTaskCount sets the "completed_task_count" field if the given value is not nil.

func (*WorkflowUpdate) SetNillableDurationMs

func (wu *WorkflowUpdate) SetNillableDurationMs(i *int64) *WorkflowUpdate

SetNillableDurationMs sets the "duration_ms" field if the given value is not nil.

func (*WorkflowUpdate) SetNillableEndedAt

func (wu *WorkflowUpdate) SetNillableEndedAt(t *time.Time) *WorkflowUpdate

SetNillableEndedAt sets the "ended_at" field if the given value is not nil.

func (*WorkflowUpdate) SetNillableErrorMessage

func (wu *WorkflowUpdate) SetNillableErrorMessage(s *string) *WorkflowUpdate

SetNillableErrorMessage sets the "error_message" field if the given value is not nil.

func (*WorkflowUpdate) SetNillableFailedTaskCount

func (wu *WorkflowUpdate) SetNillableFailedTaskCount(i *int) *WorkflowUpdate

SetNillableFailedTaskCount sets the "failed_task_count" field if the given value is not nil.

func (*WorkflowUpdate) SetNillableInitiator

func (wu *WorkflowUpdate) SetNillableInitiator(s *string) *WorkflowUpdate

SetNillableInitiator sets the "initiator" field if the given value is not nil.

func (*WorkflowUpdate) SetNillableName

func (wu *WorkflowUpdate) SetNillableName(s *string) *WorkflowUpdate

SetNillableName sets the "name" field if the given value is not nil.

func (*WorkflowUpdate) SetNillableParentWorkflowID

func (wu *WorkflowUpdate) SetNillableParentWorkflowID(s *string) *WorkflowUpdate

SetNillableParentWorkflowID sets the "parent_workflow_id" field if the given value is not nil.

func (*WorkflowUpdate) SetNillableStatus

func (wu *WorkflowUpdate) SetNillableStatus(s *string) *WorkflowUpdate

SetNillableStatus sets the "status" field if the given value is not nil.

func (*WorkflowUpdate) SetNillableTaskCount

func (wu *WorkflowUpdate) SetNillableTaskCount(i *int) *WorkflowUpdate

SetNillableTaskCount sets the "task_count" field if the given value is not nil.

func (*WorkflowUpdate) SetNillableTotalCostUsd

func (wu *WorkflowUpdate) SetNillableTotalCostUsd(f *float64) *WorkflowUpdate

SetNillableTotalCostUsd sets the "total_cost_usd" field if the given value is not nil.

func (*WorkflowUpdate) SetNillableTotalTokens

func (wu *WorkflowUpdate) SetNillableTotalTokens(i *int) *WorkflowUpdate

SetNillableTotalTokens sets the "total_tokens" field if the given value is not nil.

func (*WorkflowUpdate) SetNillableTraceID

func (wu *WorkflowUpdate) SetNillableTraceID(s *string) *WorkflowUpdate

SetNillableTraceID sets the "trace_id" field if the given value is not nil.

func (*WorkflowUpdate) SetOutput

func (wu *WorkflowUpdate) SetOutput(m map[string]interface{}) *WorkflowUpdate

SetOutput sets the "output" field.

func (*WorkflowUpdate) SetParentWorkflowID

func (wu *WorkflowUpdate) SetParentWorkflowID(s string) *WorkflowUpdate

SetParentWorkflowID sets the "parent_workflow_id" field.

func (*WorkflowUpdate) SetStatus

func (wu *WorkflowUpdate) SetStatus(s string) *WorkflowUpdate

SetStatus sets the "status" field.

func (*WorkflowUpdate) SetTaskCount

func (wu *WorkflowUpdate) SetTaskCount(i int) *WorkflowUpdate

SetTaskCount sets the "task_count" field.

func (*WorkflowUpdate) SetTotalCostUsd

func (wu *WorkflowUpdate) SetTotalCostUsd(f float64) *WorkflowUpdate

SetTotalCostUsd sets the "total_cost_usd" field.

func (*WorkflowUpdate) SetTotalTokens

func (wu *WorkflowUpdate) SetTotalTokens(i int) *WorkflowUpdate

SetTotalTokens sets the "total_tokens" field.

func (*WorkflowUpdate) SetTraceID

func (wu *WorkflowUpdate) SetTraceID(s string) *WorkflowUpdate

SetTraceID sets the "trace_id" field.

func (*WorkflowUpdate) SetUpdatedAt

func (wu *WorkflowUpdate) SetUpdatedAt(t time.Time) *WorkflowUpdate

SetUpdatedAt sets the "updated_at" field.

func (*WorkflowUpdate) Where

func (wu *WorkflowUpdate) Where(ps ...predicate.Workflow) *WorkflowUpdate

Where appends a list predicates to the WorkflowUpdate builder.

type WorkflowUpdateOne

type WorkflowUpdateOne struct {
	// contains filtered or unexported fields
}

WorkflowUpdateOne is the builder for updating a single Workflow entity.

func (*WorkflowUpdateOne) AddCompletedTaskCount

func (wuo *WorkflowUpdateOne) AddCompletedTaskCount(i int) *WorkflowUpdateOne

AddCompletedTaskCount adds i to the "completed_task_count" field.

func (*WorkflowUpdateOne) AddDurationMs

func (wuo *WorkflowUpdateOne) AddDurationMs(i int64) *WorkflowUpdateOne

AddDurationMs adds i to the "duration_ms" field.

func (*WorkflowUpdateOne) AddEventIDs

func (wuo *WorkflowUpdateOne) AddEventIDs(ids ...string) *WorkflowUpdateOne

AddEventIDs adds the "events" edge to the AgentEvent entity by IDs.

func (*WorkflowUpdateOne) AddEvents

func (wuo *WorkflowUpdateOne) AddEvents(a ...*AgentEvent) *WorkflowUpdateOne

AddEvents adds the "events" edges to the AgentEvent entity.

func (*WorkflowUpdateOne) AddFailedTaskCount

func (wuo *WorkflowUpdateOne) AddFailedTaskCount(i int) *WorkflowUpdateOne

AddFailedTaskCount adds i to the "failed_task_count" field.

func (*WorkflowUpdateOne) AddHandoffIDs

func (wuo *WorkflowUpdateOne) AddHandoffIDs(ids ...string) *WorkflowUpdateOne

AddHandoffIDs adds the "handoffs" edge to the AgentHandoff entity by IDs.

func (*WorkflowUpdateOne) AddHandoffs

func (wuo *WorkflowUpdateOne) AddHandoffs(a ...*AgentHandoff) *WorkflowUpdateOne

AddHandoffs adds the "handoffs" edges to the AgentHandoff entity.

func (*WorkflowUpdateOne) AddTaskCount

func (wuo *WorkflowUpdateOne) AddTaskCount(i int) *WorkflowUpdateOne

AddTaskCount adds i to the "task_count" field.

func (*WorkflowUpdateOne) AddTaskIDs

func (wuo *WorkflowUpdateOne) AddTaskIDs(ids ...string) *WorkflowUpdateOne

AddTaskIDs adds the "tasks" edge to the AgentTask entity by IDs.

func (*WorkflowUpdateOne) AddTasks

func (wuo *WorkflowUpdateOne) AddTasks(a ...*AgentTask) *WorkflowUpdateOne

AddTasks adds the "tasks" edges to the AgentTask entity.

func (*WorkflowUpdateOne) AddTotalCostUsd

func (wuo *WorkflowUpdateOne) AddTotalCostUsd(f float64) *WorkflowUpdateOne

AddTotalCostUsd adds f to the "total_cost_usd" field.

func (*WorkflowUpdateOne) AddTotalTokens

func (wuo *WorkflowUpdateOne) AddTotalTokens(i int) *WorkflowUpdateOne

AddTotalTokens adds i to the "total_tokens" field.

func (*WorkflowUpdateOne) ClearDurationMs

func (wuo *WorkflowUpdateOne) ClearDurationMs() *WorkflowUpdateOne

ClearDurationMs clears the value of the "duration_ms" field.

func (*WorkflowUpdateOne) ClearEndedAt

func (wuo *WorkflowUpdateOne) ClearEndedAt() *WorkflowUpdateOne

ClearEndedAt clears the value of the "ended_at" field.

func (*WorkflowUpdateOne) ClearErrorMessage

func (wuo *WorkflowUpdateOne) ClearErrorMessage() *WorkflowUpdateOne

ClearErrorMessage clears the value of the "error_message" field.

func (*WorkflowUpdateOne) ClearEvents

func (wuo *WorkflowUpdateOne) ClearEvents() *WorkflowUpdateOne

ClearEvents clears all "events" edges to the AgentEvent entity.

func (*WorkflowUpdateOne) ClearHandoffs

func (wuo *WorkflowUpdateOne) ClearHandoffs() *WorkflowUpdateOne

ClearHandoffs clears all "handoffs" edges to the AgentHandoff entity.

func (*WorkflowUpdateOne) ClearInitiator

func (wuo *WorkflowUpdateOne) ClearInitiator() *WorkflowUpdateOne

ClearInitiator clears the value of the "initiator" field.

func (*WorkflowUpdateOne) ClearInput

func (wuo *WorkflowUpdateOne) ClearInput() *WorkflowUpdateOne

ClearInput clears the value of the "input" field.

func (*WorkflowUpdateOne) ClearMetadata

func (wuo *WorkflowUpdateOne) ClearMetadata() *WorkflowUpdateOne

ClearMetadata clears the value of the "metadata" field.

func (*WorkflowUpdateOne) ClearOutput

func (wuo *WorkflowUpdateOne) ClearOutput() *WorkflowUpdateOne

ClearOutput clears the value of the "output" field.

func (*WorkflowUpdateOne) ClearParentWorkflowID

func (wuo *WorkflowUpdateOne) ClearParentWorkflowID() *WorkflowUpdateOne

ClearParentWorkflowID clears the value of the "parent_workflow_id" field.

func (*WorkflowUpdateOne) ClearTasks

func (wuo *WorkflowUpdateOne) ClearTasks() *WorkflowUpdateOne

ClearTasks clears all "tasks" edges to the AgentTask entity.

func (*WorkflowUpdateOne) ClearTraceID

func (wuo *WorkflowUpdateOne) ClearTraceID() *WorkflowUpdateOne

ClearTraceID clears the value of the "trace_id" field.

func (*WorkflowUpdateOne) Exec

func (wuo *WorkflowUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*WorkflowUpdateOne) ExecX

func (wuo *WorkflowUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*WorkflowUpdateOne) Mutation

func (wuo *WorkflowUpdateOne) Mutation() *WorkflowMutation

Mutation returns the WorkflowMutation object of the builder.

func (*WorkflowUpdateOne) RemoveEventIDs

func (wuo *WorkflowUpdateOne) RemoveEventIDs(ids ...string) *WorkflowUpdateOne

RemoveEventIDs removes the "events" edge to AgentEvent entities by IDs.

func (*WorkflowUpdateOne) RemoveEvents

func (wuo *WorkflowUpdateOne) RemoveEvents(a ...*AgentEvent) *WorkflowUpdateOne

RemoveEvents removes "events" edges to AgentEvent entities.

func (*WorkflowUpdateOne) RemoveHandoffIDs

func (wuo *WorkflowUpdateOne) RemoveHandoffIDs(ids ...string) *WorkflowUpdateOne

RemoveHandoffIDs removes the "handoffs" edge to AgentHandoff entities by IDs.

func (*WorkflowUpdateOne) RemoveHandoffs

func (wuo *WorkflowUpdateOne) RemoveHandoffs(a ...*AgentHandoff) *WorkflowUpdateOne

RemoveHandoffs removes "handoffs" edges to AgentHandoff entities.

func (*WorkflowUpdateOne) RemoveTaskIDs

func (wuo *WorkflowUpdateOne) RemoveTaskIDs(ids ...string) *WorkflowUpdateOne

RemoveTaskIDs removes the "tasks" edge to AgentTask entities by IDs.

func (*WorkflowUpdateOne) RemoveTasks

func (wuo *WorkflowUpdateOne) RemoveTasks(a ...*AgentTask) *WorkflowUpdateOne

RemoveTasks removes "tasks" edges to AgentTask entities.

func (*WorkflowUpdateOne) Save

func (wuo *WorkflowUpdateOne) Save(ctx context.Context) (*Workflow, error)

Save executes the query and returns the updated Workflow entity.

func (*WorkflowUpdateOne) SaveX

func (wuo *WorkflowUpdateOne) SaveX(ctx context.Context) *Workflow

SaveX is like Save, but panics if an error occurs.

func (*WorkflowUpdateOne) Select

func (wuo *WorkflowUpdateOne) Select(field string, fields ...string) *WorkflowUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*WorkflowUpdateOne) SetCompletedTaskCount

func (wuo *WorkflowUpdateOne) SetCompletedTaskCount(i int) *WorkflowUpdateOne

SetCompletedTaskCount sets the "completed_task_count" field.

func (*WorkflowUpdateOne) SetDurationMs

func (wuo *WorkflowUpdateOne) SetDurationMs(i int64) *WorkflowUpdateOne

SetDurationMs sets the "duration_ms" field.

func (*WorkflowUpdateOne) SetEndedAt

func (wuo *WorkflowUpdateOne) SetEndedAt(t time.Time) *WorkflowUpdateOne

SetEndedAt sets the "ended_at" field.

func (*WorkflowUpdateOne) SetErrorMessage

func (wuo *WorkflowUpdateOne) SetErrorMessage(s string) *WorkflowUpdateOne

SetErrorMessage sets the "error_message" field.

func (*WorkflowUpdateOne) SetFailedTaskCount

func (wuo *WorkflowUpdateOne) SetFailedTaskCount(i int) *WorkflowUpdateOne

SetFailedTaskCount sets the "failed_task_count" field.

func (*WorkflowUpdateOne) SetInitiator

func (wuo *WorkflowUpdateOne) SetInitiator(s string) *WorkflowUpdateOne

SetInitiator sets the "initiator" field.

func (*WorkflowUpdateOne) SetInput

func (wuo *WorkflowUpdateOne) SetInput(m map[string]interface{}) *WorkflowUpdateOne

SetInput sets the "input" field.

func (*WorkflowUpdateOne) SetMetadata

func (wuo *WorkflowUpdateOne) SetMetadata(m map[string]interface{}) *WorkflowUpdateOne

SetMetadata sets the "metadata" field.

func (*WorkflowUpdateOne) SetName

func (wuo *WorkflowUpdateOne) SetName(s string) *WorkflowUpdateOne

SetName sets the "name" field.

func (*WorkflowUpdateOne) SetNillableCompletedTaskCount

func (wuo *WorkflowUpdateOne) SetNillableCompletedTaskCount(i *int) *WorkflowUpdateOne

SetNillableCompletedTaskCount sets the "completed_task_count" field if the given value is not nil.

func (*WorkflowUpdateOne) SetNillableDurationMs

func (wuo *WorkflowUpdateOne) SetNillableDurationMs(i *int64) *WorkflowUpdateOne

SetNillableDurationMs sets the "duration_ms" field if the given value is not nil.

func (*WorkflowUpdateOne) SetNillableEndedAt

func (wuo *WorkflowUpdateOne) SetNillableEndedAt(t *time.Time) *WorkflowUpdateOne

SetNillableEndedAt sets the "ended_at" field if the given value is not nil.

func (*WorkflowUpdateOne) SetNillableErrorMessage

func (wuo *WorkflowUpdateOne) SetNillableErrorMessage(s *string) *WorkflowUpdateOne

SetNillableErrorMessage sets the "error_message" field if the given value is not nil.

func (*WorkflowUpdateOne) SetNillableFailedTaskCount

func (wuo *WorkflowUpdateOne) SetNillableFailedTaskCount(i *int) *WorkflowUpdateOne

SetNillableFailedTaskCount sets the "failed_task_count" field if the given value is not nil.

func (*WorkflowUpdateOne) SetNillableInitiator

func (wuo *WorkflowUpdateOne) SetNillableInitiator(s *string) *WorkflowUpdateOne

SetNillableInitiator sets the "initiator" field if the given value is not nil.

func (*WorkflowUpdateOne) SetNillableName

func (wuo *WorkflowUpdateOne) SetNillableName(s *string) *WorkflowUpdateOne

SetNillableName sets the "name" field if the given value is not nil.

func (*WorkflowUpdateOne) SetNillableParentWorkflowID

func (wuo *WorkflowUpdateOne) SetNillableParentWorkflowID(s *string) *WorkflowUpdateOne

SetNillableParentWorkflowID sets the "parent_workflow_id" field if the given value is not nil.

func (*WorkflowUpdateOne) SetNillableStatus

func (wuo *WorkflowUpdateOne) SetNillableStatus(s *string) *WorkflowUpdateOne

SetNillableStatus sets the "status" field if the given value is not nil.

func (*WorkflowUpdateOne) SetNillableTaskCount

func (wuo *WorkflowUpdateOne) SetNillableTaskCount(i *int) *WorkflowUpdateOne

SetNillableTaskCount sets the "task_count" field if the given value is not nil.

func (*WorkflowUpdateOne) SetNillableTotalCostUsd

func (wuo *WorkflowUpdateOne) SetNillableTotalCostUsd(f *float64) *WorkflowUpdateOne

SetNillableTotalCostUsd sets the "total_cost_usd" field if the given value is not nil.

func (*WorkflowUpdateOne) SetNillableTotalTokens

func (wuo *WorkflowUpdateOne) SetNillableTotalTokens(i *int) *WorkflowUpdateOne

SetNillableTotalTokens sets the "total_tokens" field if the given value is not nil.

func (*WorkflowUpdateOne) SetNillableTraceID

func (wuo *WorkflowUpdateOne) SetNillableTraceID(s *string) *WorkflowUpdateOne

SetNillableTraceID sets the "trace_id" field if the given value is not nil.

func (*WorkflowUpdateOne) SetOutput

func (wuo *WorkflowUpdateOne) SetOutput(m map[string]interface{}) *WorkflowUpdateOne

SetOutput sets the "output" field.

func (*WorkflowUpdateOne) SetParentWorkflowID

func (wuo *WorkflowUpdateOne) SetParentWorkflowID(s string) *WorkflowUpdateOne

SetParentWorkflowID sets the "parent_workflow_id" field.

func (*WorkflowUpdateOne) SetStatus

func (wuo *WorkflowUpdateOne) SetStatus(s string) *WorkflowUpdateOne

SetStatus sets the "status" field.

func (*WorkflowUpdateOne) SetTaskCount

func (wuo *WorkflowUpdateOne) SetTaskCount(i int) *WorkflowUpdateOne

SetTaskCount sets the "task_count" field.

func (*WorkflowUpdateOne) SetTotalCostUsd

func (wuo *WorkflowUpdateOne) SetTotalCostUsd(f float64) *WorkflowUpdateOne

SetTotalCostUsd sets the "total_cost_usd" field.

func (*WorkflowUpdateOne) SetTotalTokens

func (wuo *WorkflowUpdateOne) SetTotalTokens(i int) *WorkflowUpdateOne

SetTotalTokens sets the "total_tokens" field.

func (*WorkflowUpdateOne) SetTraceID

func (wuo *WorkflowUpdateOne) SetTraceID(s string) *WorkflowUpdateOne

SetTraceID sets the "trace_id" field.

func (*WorkflowUpdateOne) SetUpdatedAt

func (wuo *WorkflowUpdateOne) SetUpdatedAt(t time.Time) *WorkflowUpdateOne

SetUpdatedAt sets the "updated_at" field.

func (*WorkflowUpdateOne) Where

Where appends a list predicates to the WorkflowUpdate builder.

type Workflows

type Workflows []*Workflow

Workflows is a parsable slice of Workflow.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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