# Class ArtifactStore

In-memory artifact store with bounded capacity.

When the store exceeds maxArtifacts, the oldest artifacts are evicted (FIFO). Content size is validated on put().

#### Implements

- IArtifactStore

- Defined in packages/nexus-agents/src/pipeline/artifact-store.ts:132

##### Index

### Constructors

constructor

### Accessors

size

### Methods

put
get
query
provenance

## Constructors

### constructor

- new ArtifactStore(options?: ArtifactStoreOptions): ArtifactStore

  #### Parameters

  - `Optional` options: ArtifactStoreOptions

  #### Returns ArtifactStore

  - Defined in packages/nexus-agents/src/pipeline/artifact-store.ts:138

## Accessors

### size

- get size(): number

  #### Returns number

  Implementation of IArtifactStore.size

  - Defined in packages/nexus-agents/src/pipeline/artifact-store.ts:143

## Methods

### put

- put(
  artifact: Artifact,
  ): {
  id: string;
  type:
  | "code"
  | "plan"
  | "analysis"
  | "review"
  | "test"
  | "spec"
  | "report"
  | "vote";
  }

  #### Parameters

  - artifact: Artifact

  #### Returns {
  id: string;
  type:
  | "code"
  | "plan"
  | "analysis"
  | "review"
  | "test"
  | "spec"
  | "report"
  | "vote";
  }

  Implementation of IArtifactStore.put

  - Defined in packages/nexus-agents/src/pipeline/artifact-store.ts:147

### get

- get(
  ref: {
  id: string;
  type:
  | "code"
  | "plan"
  | "analysis"
  | "review"
  | "test"
  | "spec"
  | "report"
  | "vote";
  },
  ): Artifact
  | undefined

  #### Parameters

  - ref: {
    id: string;
    type:
    | "code"
    | "plan"
    | "analysis"
    | "review"
    | "test"
    | "spec"
    | "report"
    | "vote";
    }

  #### Returns Artifact | undefined

  Implementation of IArtifactStore.get

  - Defined in packages/nexus-agents/src/pipeline/artifact-store.ts:165

### query

- query(
  filter: ArtifactFilter,
  ): readonly {
  id: string;
  type:
  | "code"
  | "plan"
  | "analysis"
  | "review"
  | "test"
  | "spec"
  | "report"
  | "vote";
  }[]

  #### Parameters

  - filter: ArtifactFilter

  #### Returns readonly {
  id: string;
  type:
  | "code"
  | "plan"
  | "analysis"
  | "review"
  | "test"
  | "spec"
  | "report"
  | "vote";
  }[]

  Implementation of IArtifactStore.query

  - Defined in packages/nexus-agents/src/pipeline/artifact-store.ts:169

### provenance

- provenance(
  ref: {
  id: string;
  type:
  | "code"
  | "plan"
  | "analysis"
  | "review"
  | "test"
  | "spec"
  | "report"
  | "vote";
  },
  ): readonly ProvenanceEntry[]

  #### Parameters

  - ref: {
    id: string;
    type:
    | "code"
    | "plan"
    | "analysis"
    | "review"
    | "test"
    | "spec"
    | "report"
    | "vote";
    }

  #### Returns readonly ProvenanceEntry[]

  Implementation of IArtifactStore.provenance

  - Defined in packages/nexus-agents/src/pipeline/artifact-store.ts:178