Skip to main content

PinnAItor Logo

PinnAItor

A platform for AI Agents and AI Agents products generation.

Overview

PinnAItor is a cutting-edge platform designed to generate AI agents and related products that help automate complex tasks and processes. It leverages state-of-the-art machine learning libraries and tools to deliver flexible and scalable AI solutions.

PinnAItor was previously developed under the name genaitor. It has been renamed to establish its own independent identity on PyPI and GitHub.

Install from PyPI

pip install pinnaitor

Install from source

To install the required dependencies from a clone of this repository, follow these steps:

  1. Clone the repository:

    git clone https://github.com/PINNeAPPle-Labs/pinnaitor.git
    cd pinnaitor
    
  2. Create a virtual environment (optional but recommended):

    python -m venv venv
    source venv/bin/activate  # On Windows use `venv\Scripts\activate`
    
  3. Install the required packages:

    pip install -e .
    
  4. Add API_KEY for llm (Gemini set as main, but you can use Anthropic, OpenAI, DeepSeek, Grok, Ollama or a custom LLM model):

    echo "API_KEY=your_gemini_api_key" >> .env
    

General Framework Architecture

General Diagram

Features

  • Generate AI agents for a variety of use cases.
  • Modular architecture with components such as core, llm, utils, and presets.
  • Support for multiple data processing and communication protocols.
  • Integration with popular libraries like Transformers, Langchain, and more.

Usage

Basic Example

Here’s a simple example of how to create an agent that answers questions using a generative model:

from pinnaitor.core import Agent, Task
from pinnaitor.llm import GeminiProvider, GeminiConfig

# Define a custom task
class QuestionAnsweringTask(Task):
    def __init__(self, description: str, goal: str, output_format: str, llm_provider):
        super().__init__(description, goal, output_format)
        self.llm = llm_provider

    def execute(self, input_data: str):
        prompt = f"""
        Task: {self.description}
        Goal: {self.goal}
        Question: {input_data}
        Please provide a response following the format:
        {self.output_format}
        """
        return self.llm.generate(prompt)

# Configure the LLM provider
llm_provider = GeminiProvider(GeminiConfig(api_key="your_api_key"))

# Create an agent
agent = Agent(role="QA Agent", tasks=[QuestionAnsweringTask("Answering questions", "Provide accurate answers", "Text format", llm_provider)])

# Execute a task
for task in agent.tasks:
    result = task.execute("What is AI?")
    print(result)

Multi-Agent Example

Here’s a simple example of how to create a flow using multiple agents:

import asyncio
from pinnaitor.core import (
    Agent, Task, Orchestrator, Flow,
    ExecutionMode, AgentRole, TaskResult
)
from pinnaitor.llm import GeminiProvider, GeminiConfig

# Define a base task (you could use different tasks for each agent)
class LLMTask(Task):
    def __init__(self, description: str, goal: str, output_format: str, llm_provider):
        super().__init__(description, goal, output_format)
        self.llm = llm_provider

    def execute(self, input_data: str) -> TaskResult:
        prompt = f"""
        Task: {self.description}
        Goal: {self.goal}
        
        Input: {input_data}
        
        Please provide a response following the format:
        {self.output_format}
        """
        
        try:
            response = self.llm.generate(prompt)
            return TaskResult(
                success=True,
                content=response,
                metadata={"task_type": self.description}
            )
        except Exception as e:
            return TaskResult(
                success=False,
                content=None,
                error=str(e)
            )

# Configure the LLM provider
llm_provider = GeminiProvider(GeminiConfig(api_key="your_api_key"))

# Generating two specific tasks
qa_task = LLMTask(
    description="Question Answering",
    goal="Provide clear and accurate responses",
    output_format="Concise and informative",
    llm_provider=llm_provider
)
    
summarization_task = LLMTask(
    description="Text Summarization",
    goal="Summarize lengthy content into key points",
    output_format="Bullet points or short paragraph",
    llm_provider=llm_provider
)

# Create agents
qa_agent = Agent(
    role=AgentRole.SPECIALIST,
    tasks=[qa_task],
    llm_provider=llm_provider
)
summarization_agent = Agent(
    role=AgentRole.SUMMARIZER,
    tasks=[summarization_task],
    llm_provider=llm_provider
)

orchestrator = Orchestrator(
    agents={"qa_agent": qa_agent, "summarization_agent": summarization_agent},
    flows={
        "default_flow": Flow(agents=["qa_agent", "summarization_agent"], context_pass=[True,True])
    },
    mode=ExecutionMode.SEQUENTIAL
)
    
result_process = orchestrator.process_request('What is the impact of AI on modern healthcare?', flow_name='default_flow')
result = asyncio.run(result_process)
print(result)

Examples usage

Here is a simple guideline for running the examples

Streamlit APPs

streamlit run apps/pinneaple.py

General examples

python examples/autism_assistant.py

Demo Videos

Here are some demo videos showcasing PinnAItor in action:

FAQ

Why should I use this framework over others like LangChain, LangGraph, CrewAI or LlamaIndex?

While popular frameworks like LangChain, LangGraph, and LlamaIndex are powerful, they are primarily designed as general-purpose agentic frameworks. Our framework is specifically optimized for Scientific Machine Learning (SciML) applications and offers the following key advantages:

  • Specific focus on Scientific Machine Learning: Unlike generalist frameworks, we prioritize workflows tailored for scientific and physics-based AI tasks, where agent behavior often requires structured reasoning and domain-specific knowledge handling.

  • Greater control and transparency: Our design provides developers with direct access to agent modeling and lifecycle management. You are not tied to predefined abstractions or "black-box" architectures, allowing full customization to match scientific workflows.

  • Reduced learning curve: Our framework minimizes unnecessary complexity. Users can build efficient agents with a much simpler and more intuitive interface, without needing to dive deep into multiple layers of abstractions before achieving results.

Is this framework compatible with LangChain or LlamaIndex?

Our framework is independent but compatible with most libraries from the ecosystem. You can integrate components like LlamaIndex for document retrieval or LangChain tools if needed, while still maintaining full control over the agent lifecycle inside our framework.

What kind of Scientific Machine Learning tasks is this framework suited for?

This framework is designed for tasks such as:

  • Physics-informed problem solving

  • Scientific reasoning and simulation control

  • AI-driven research assistants for scientific domains

  • Autonomous agents for data-driven discovery processes

  • Interaction with physical simulation APIs, datasets, and analytical tools

If your use case involves structured reasoning, scientific models, or physics-based tasks, this framework provides the flexibility and precision you need.

Contribution Guidelines

We welcome contributions! To contribute:

  1. Fork the repository.
  2. Create a new branch (git checkout -b feature-name).
  3. Make your changes and commit (git commit -m 'Add new feature').
  4. Push to the branch (git push origin feature-name).
  5. Create a pull request.

License

This project is licensed under the MIT License.

Contact

For any questions or suggestions, feel free to open an issue or contact the maintainers at executive.enterpriselm@gmail.com or the main author Yan Barros at https://www.linkedin.com/in/yan-barros-yan

You can also check our landing-page to more news:

enterpriselm.github.io/home

Metadata

Release files for pinnaitor 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pinnaitor 0.1.0
File Size Uploaded Provenance Actions
pinnaitor-0.1.0.tar.gz 44.0 kB Without provenance Details for pinnaitor-0.1.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for pinnaitor 0.1.0
File Interpreter ABI Platform Actions
pinnaitor-0.1.0-py3-none-any.whl Python 3 none any Details for pinnaitor-0.1.0-py3-none-any.whl

Total release size: 90.0 kB

Release files / pinnaitor-0.1.0.tar.gz

Download URL pinnaitor-0.1.0.tar.gz
Size 44.0 kB
Tags Source
SHA-256 checksum
How to use checksums
fdd20cbee44a1a9b162ddef7fba623c90c47ac7c0724ffa2bf342cd029295364
BLAKE2b-256 checksum
How to use checksums
df7bb763de0123a2f2e3d71f1ba26d8c7b176e2cc0e4953175c6112a1c91b0d8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.6

Release files / pinnaitor-0.1.0-py3-none-any.whl

Download URL pinnaitor-0.1.0-py3-none-any.whl
Size 46.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
592fcd2a744c3b85eb96cd110c548962d1cf7b5c5a9d854fd72c7e69bdfa8b2b
BLAKE2b-256 checksum
How to use checksums
beb750183de9907ef3dcb243623e30e62082fccdac06c84cb19e9841522c4edf
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.6

Security for pinnaitor 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page