Skip to content

Commit

Permalink
Merge pull request #267 from agential-ai/clin_agent
Browse files Browse the repository at this point in the history
CLIN Agent
  • Loading branch information
alckasoc authored Nov 6, 2024
2 parents d3c9862 + 1a664cf commit 9fadbba
Show file tree
Hide file tree
Showing 140 changed files with 33,742 additions and 5,252 deletions.
131 changes: 117 additions & 14 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -155,28 +155,131 @@ pre-commit install

## 3. 🧭 Navigating the Repository

Head to the `agential` where the project source code is. Within the `cog` directory, you'll find various modules and subdirectories catering to different aspects of the project's functionality.

- `agent`: Agent implementations
- `eval`: Evaluation module
- `functional`: Low-level functions for implementing agents
- `modules`: Submodules with specific functionalities like memory, planning, reflection, and scoring.
- `persona`: Default persona for agents, if applicable
- `prompts`: Agent prompts and a few-shot examples
- `utils`: Utility functions for fetching, formatting, parsing, etc.


Please take a look at the [README](https://github.com/alckasoc/agential/blob/main/README.md) for a well-structured overview of the project!
```
├── agential <- Library folder.
├── data/ <- Data folder with each benchmark containing its data.
│ ├── <benchmark-name>/
│ │ ├── README.md
│ │ └── main.ipynb
│ └── ...
├── docs <- Documentation.
├── experiments/ <- Experiments with each method folder containing scripts, one for each benchmark.
│ ├── <method-name>/
│ │ ├── <benchmark-name>.py
│ │ ├── ...
│ │ └── run.sh
│ └── ...
├── notebooks/ <- Notebooks to show library usage, one for each agent.
│ └── <method-name>.ipynb
├── reports <- Diagrams, figures, images, whiteboards.
└── tests <- Unit tests, structure reflects agential.
```
_Overall repository structure._

## 4. ⚒️ What do I work on?
```
agential/
├── agents/
│ ├── base/
│ │ ├── modules/
│ │ │ ├── memory.py
│ │ │ └── reflect.py
│ │ ├── agent.py
│ │ ├── output.py
│ │ └── strategies.py
│ │
│ ├── <agentic-method-name>/
│ │ ├── strategies/
│ │ │ ├── base.py
│ │ │ ├── code.py
│ │ │ ├── general.py
│ │ │ ├── math.py
│ │ │ └── qa.py
│ │ ├── agent.py
│ │ ├── functional.py
│ │ ├── output.py
│ │ └── prompts.py
│ └── ...
├── core/
│ ├── base/
│ │ ├── method.py
│ │ ├── output.py
│ │ └── strategies.py
│ ├── fewshots/
│ │ └── <benchmark-name>.py
│ └── llm.py
├── eval/
│ └── metrics/
│ └── classification.py
├── prompting/
│ ├── base/
│ │ ├── output.py
│ │ ├── prompting.py
│ │ └── strategies.py
│ │
│ ├── <prompting-method-name>/
│ │ ├── strategies/
│ │ │ ├── base.py
│ │ │ ├── code.py
│ │ │ ├── general.py
│ │ │ ├── math.py
│ │ │ └── qa.py
│ │ ├── functional.py
│ │ ├── output.py
│ │ ├── prompting.py
│ │ └── prompts.py
│ └── ...
|
├── utils/
│ ├── docstore.py
│ ├── general.py
│ ├── parse.py
│ └── validation.py
└── constants.py
```
_Structure of Agential._


## 4. 🎹 Onboarding

It's integral to get up to speed on the project before you start contributing! There are 2 focuses in onboarding:
- **Understanding the code**
- Understand the structure of the library, the purpose of each folder and modules; notice repeating patterns and reference the tree diagrams above
- Understand the base classes and files as they're integral to the rest of the library
- Understand core methods in classes that are used and understand how the library is used
- **Understanding the literature**
- Read through survey paper(s) to survey the field
- Read through the core papers of our library
- Survey: https://arxiv.org/abs/2309.07864
- Survey: https://arxiv.org/abs/2309.14365
- Survey: https://arxiv.org/abs/2308.11432
- Conceptual: https://arxiv.org/abs/2309.02427
- Methods
- Prompting
- Chain-of-Thought: https://arxiv.org/abs/2201.11903
- Self-Refine: https://arxiv.org/pdf/2303.17651
- Agentic
- ReAct: https://arxiv.org/abs/2210.03629
- Reflexion: https://arxiv.org/abs/2303.11366
- CRITIC: https://arxiv.org/pdf/2305.11738
- ExpeL: https://arxiv.org/pdf/2308.10144
- LATS: https://arxiv.org/abs/2310.04406
- CLIN: https://arxiv.org/pdf/2310.10134
- AgentOptimizer: https://arxiv.org/pdf/2402.11359

After this, you're ready to start contributing!

## 5. ⚒️ What do I work on?

You can start by browsing through our list of [issues](https://github.com/alckasoc/agential/issues) or suggesting your own!

Once you’ve decided on an issue, leave a comment and wait for approval! We don't want multiple people on a single issue unless the issue stresses it!

If you’re ever in doubt about whether or not a proposed feature aligns with our library, feel free to raise an issue about it and we’ll get back to you promptly!

## 5. ❓ Questions
## 6. ❓ Questions

Feel free to contact [Vincent Tu](https://www.linkedin.com/in/vincent%2Dtu%2D422b18208/), our lead contributor. We're very friendly and welcoming to new contributors, so don't hesitate to reach out! 🙂

Expand Down
40 changes: 0 additions & 40 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,46 +41,6 @@ agent = ReActAgent(llm=llm, benchmark="hotpotqa")
out = agent.generate(question=question)
```


## 🧭 Project Organization

------------

├── agential <- Source code for this project.
│   ├── cog
│ │ ├── agent <- Model/agent-related modules.
│ │ │ ├── strategies <- Strategies encapsulate agent logic for each benchmark/benchmark type.
│ │ │ │ ├── base.py
│ │ │ │ ├── qa.py
│ │ │ │ ├── math.py
│ │ │ │ └── code.py
│ │ │ │
│ │ │ ├── agent.py <- Agent class responsible for selecting the correct strategy, prompts/few-shots, and generating responses.
│ │ │ ├── functional.py <- Functional methods for agent. The lowest level of abstraction.
│ │ │ ├── output.py <- Output class responsible for formatting the response from the agents.
│ │ │ ├── prompts.py <- Prompt templates.
│ │ │ └── <modules>.py <- Any additional modules you may have for the strategies. Agnostic to benchmarks/benchmark-types.
│ │
│   ├── eval <- Evaluation-related modules.
│ │
│   ├── llm <- LLM class.
│ │
│ └── utils <- Utility methods.
├── docs <- An mkdocs project.
├── notebooks <- Jupyter notebooks. Naming convention is a number
│ (for ordering), the creator's initials, and a short `-` delimited │ description, e.g. `1.0-jqp-initial-data-exploration`.
├── references <- Data dictionaries, manuals, and all other explanatory materials.
├── reports <- Generated analysis as HTML, PDF, LaTeX, etc.
│   └── figures <- Generated graphics and figures to be used in reporting.
└── tests <- Tests.

---------

## 🙏 Acknowledgement

## 😀 Contributing
Expand Down
1 change: 1 addition & 0 deletions agential/agents/clin/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
"""CLIN agent."""
Loading

0 comments on commit 9fadbba

Please sign in to comment.