Skip to main content

CLI Commands

resources

The resources command manages resources for MCP servers, such as model weights, configuration files, and datasets.

Usage

cogni resources [COMMAND] [OPTIONS]

Description

The resources command provides tools for managing the various resources needed by MCP servers. This includes uploading, downloading, and managing model weights, configuration files, datasets, and other assets. Resources are stored securely in the Cogni+ Platform and can be referenced by your MCP servers during development and deployment.

Subcommands

SubcommandDescription
listList resources available to your account
uploadUpload a new resource to the Cogni+ Platform
downloadDownload a resource to your local environment
deleteDelete a resource from the Cogni+ Platform
infoShow detailed information about a resource
linkLink a resource to an MCP server
unlinkRemove a link between a resource and an MCP server

Common Options

OptionDescription
--helpShow help message for the resources command or subcommand

Examples

List Resources

# List all resources
cogni resources list

# List resources of a specific type
cogni resources list --type model-weights

# List resources linked to a specific server
cogni resources list --server my-custom-model

Upload Resources

# Upload a model weights file
cogni resources upload --type model-weights --name "llama3-weights" model_weights.bin

# Upload a configuration file
cogni resources upload --type config --name "llama3-config" config.json

# Upload a dataset with description
cogni resources upload --type dataset --name "training-data" --description "Custom fine-tuning dataset" dataset.jsonl

Download Resources

# Download a resource
cogni resources download resource_id

# Download to a specific location
cogni resources download --output ./my-folder/ resource_id

Resource Types

Cogni+ supports several types of resources:
  • model-weights: Model parameter files
  • config: Configuration files
  • dataset: Training or evaluation datasets
  • embeddings: Pre-computed embeddings
  • tokenizer: Tokenizer files
  • other: Miscellaneous files

Output

For the list command:
Available Resources:
ID                   | Name            | Type          | Size    | Created
---------------------|-----------------|---------------|---------|------------------
res_1a2b3c4d5e6f7g   | llama3-weights  | model-weights | 15.2 GB | 2023-10-15 14:30
res_2b3c4d5e6f7g8h   | llama3-config   | config        | 12 KB   | 2023-10-15 14:35
res_3c4d5e6f7g8h9i   | training-data   | dataset       | 3.1 GB  | 2023-10-16 09:20
For the info command:
Resource Information:
ID: res_1a2b3c4d5e6f7g
Name: llama3-weights
Type: model-weights
Size: 15.2 GB
Created: 2023-10-15 14:30:45
Last modified: 2023-10-15 14:30:45
Description: LLaMA 3 model weights (70B parameter version)
Linked servers:
  - my-llama3-server
  - my-custom-chatbot

Security

Resources are securely stored in the Cogni+ Platform with encryption at rest and in transit. Access is controlled by your account permissions and organization settings.

Tips

  • Use descriptive names and add descriptions to resources for better organization
  • For large resources, ensure you have a stable internet connection
  • Resources are stored at the organization level and can be shared between team members
  • Link resources to servers to make them automatically available during deployment