Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: atoma provider #2082

Open
wants to merge 23 commits into
base: develop
Choose a base branch
from

Conversation

francis2tm
Copy link

@francis2tm francis2tm commented Jan 9, 2025

Background

Atoma is a decentralized private and verifiable AI execution network. It provides the infrastructure for developers and enterprises to use open-source AI models and build AI applications with full privacy.

What does this PR do?

Adds Atoma Network as an inference provider

What kind of change is this?

Features (non-breaking change which adds functionality)

Web3 Agents deserve a decentralized AI cloud.

Documentation changes needed?

Yes, add atoma provider docs

Testing

Ran pnpm start --character="characters/trump.character.json" with "modelProvider": "atoma"

Where should a reviewer start?

Detailed testing steps

Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @francis2tm! Welcome to the ai16z community. Thanks for submitting your first pull request; your efforts are helping us accelerate towards AGI. We'll review it shortly. You are now a ai16z contributor!

@francis2tm francis2tm changed the title Feat/atoma provider feat: atoma provider Jan 9, 2025
…eason, usage metrics, and timestamp conversion
packages/core/src/models.ts Outdated Show resolved Hide resolved
packages/core/src/generation.ts Outdated Show resolved Hide resolved
…K version change

- Added Atoma API URL and model configurations to .env.example.
- Updated pnpm-lock.yaml to reference the latest Atoma SDK version.
- Enhanced index.ts to include Atoma as a model provider for token retrieval.
- Implemented Atoma model initialization and response handling in generation.ts.
- Updated models.ts to utilize dynamic settings for Atoma model classes.
…dels.ts

- Deleted EMBEDDING_ATOMA_MODEL and IMAGE_ATOMA_MODEL from .env.example.
- Removed corresponding model class settings from models.ts to streamline configuration.
…and consistency

- Updated Atoma model settings in models.ts to encapsulate parameters (stop, maxInputTokens, maxOutputTokens, temperature) within each model class.
- Reformatted code for better readability and maintainability.
- Minor formatting adjustments in types.ts for consistency in enum declaration and interface method signatures.
@francis2tm francis2tm changed the base branch from main to develop January 16, 2025 00:39
- Standardized import statements and removed unnecessary line breaks.
- Simplified function definitions and improved inline comments for clarity.
- Enhanced logging messages for better debugging and error tracking.
- Ensured consistent use of single quotes for strings throughout the file.
- Deleted the handleAtoma function, which was responsible for generating objects for Atoma models.
- This change simplifies the codebase by removing unused functionality, improving maintainability.
@francis2tm francis2tm marked this pull request as ready for review January 16, 2025 01:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants