promptulate


Namepromptulate JSON
Version 1.15.3 PyPI version JSON
download
home_pagehttps://github.com/Undertone0809/promptulate
SummaryA powerful LLM Application development framework.
upload_time2024-04-23 13:49:54
maintainerNone
docs_urlNone
authorZeeland
requires_python<4.0,>=3.8.1
licenseNone
keywords promptulate pne prompt agent openai chatgpt gpt llm openai langchain litellm
VCS
bugtrack_url
requirements aiohttp aiosignal annotated-types anyio async-timeout attrs broadcast-service certifi charset-normalizer click colorama cushy-storage distro exceptiongroup filelock frozenlist fsspec h11 httpcore httpx huggingface-hub idna importlib-metadata jinja2 litellm loguru markupsafe multidict numexpr numpy openai packaging prompt-toolkit pydantic-core pydantic python-dotenv pyyaml questionary regex requests sniffio tiktoken tokenizers tqdm typing-extensions urllib3 wcwidth win32-setctime yarl zipp
Travis-CI No Travis.
coveralls test coverage No coveralls.
            <h1 align="center">
    Promptulate
</h1>

<p align="center">
    <a target="_blank" href="">
        <img src="https://img.shields.io/github/license/Undertone0809/promptulate.svg?style=flat-square" />
    </a>
    <a target="_blank" href=''>
        <img src="https://img.shields.io/github/release/Undertone0809/promptulate/all.svg?style=flat-square"/>
    </a>
    <a target="_blank" href=''>
        <img src="https://bestpractices.coreinfrastructure.org/projects/3018/badge"/>
   </a>
    <a target="_blank" href=''>
        <img src="https://static.pepy.tech/personalized-badge/promptulate?period=month&units=international_system&left_color=grey&right_color=blue&left_text=Downloads/Week"/>
    </a>
    <a target="_blank" href=''>
        <img src="docs/images/coverage.svg"/>
    </a>
</p>

[English](/README.md) [δΈ­ζ–‡](/README_zh.md)

<p align="center">
  <img src="https://zeeland-bucket.oss-cn-beijing.aliyuncs.com/images/promptulate_logo_new.png"/>
</p>

## Overview

**Promptulate** is an AI Agent application development framework crafted by **Cogit Lab**, which offers developers an extremely concise and efficient way to build Agent applications through a Pythonic development paradigm. The core philosophy of Promptulate is to borrow and integrate the wisdom of the open-source community, incorporating the highlights of various development frameworks to lower the barrier to entry and unify the consensus among developers. With Promptulate, you can manipulate components like LLM, Agent, Tool, RAG, etc., with the most succinct code, as most tasks can be easily completed with just a few lines of code. πŸš€

## πŸ’‘ Features

- 🐍 Pythonic Code Style: Embraces the habits of Python developers, providing a Pythonic SDK calling approach, putting everything within your grasp with just one `pne.chat` function to encapsulate all essential functionalities.
- 🧠 Model Compatibility: Supports nearly all types of large models on the market and allows for easy customization to meet specific needs.
- πŸ•΅οΈβ€β™‚οΈ Diverse Agents: Offers various types of Agents, such as WebAgent, ToolAgent, CodeAgent, etc., capable of planning, reasoning, and acting to handle complex problems.
- πŸ”— Low-Cost Integration: Effortlessly integrates tools from different frameworks like LangChain, significantly reducing integration costs.
- πŸ”¨ Functions as Tools: Converts any Python function directly into a tool usable by Agents, simplifying the tool creation and usage process.
- πŸͺ Lifecycle and Hooks: Provides a wealth of Hooks and comprehensive lifecycle management, allowing the insertion of custom code at various stages of Agents, Tools, and LLMs.
- πŸ’» Terminal Integration: Easily integrates application terminals, with built-in client support, offering rapid debugging capabilities for prompts.
- ⏱️ Prompt Caching: Offers a caching mechanism for LLM Prompts to reduce repetitive work and enhance development efficiency.

> Below, `pne` stands for Promptulate, which is the nickname for Promptulate. The `p` and `e` represent the beginning and end of Promptulate, respectively, and `n` stands for 9, which is a shorthand for the nine letters between `p` and `e`.

## Supported Base Models

Promptulate integrates the capabilities of [litellm](https://github.com/BerriAI/litellm), supporting nearly all types of large models on the market, including but not limited to the following models:

| Provider      | [Completion](https://docs.litellm.ai/docs/#basic-usage) | [Streaming](https://docs.litellm.ai/docs/completion/stream#streaming-responses)  | [Async Completion](https://docs.litellm.ai/docs/completion/stream#async-completion)  | [Async Streaming](https://docs.litellm.ai/docs/completion/stream#async-streaming)  | [Async Embedding](https://docs.litellm.ai/docs/embedding/supported_embedding)  | [Async Image Generation](https://docs.litellm.ai/docs/image_generation)  | 
| ------------- | ------------- | ------------- | ------------- | ------------- | ------------- | ------------- |
| [openai](https://docs.litellm.ai/docs/providers/openai)  | βœ… | βœ… | βœ… | βœ… | βœ… | βœ… |
| [azure](https://docs.litellm.ai/docs/providers/azure)  | βœ… | βœ… | βœ… | βœ… | βœ… | βœ… |
| [aws - sagemaker](https://docs.litellm.ai/docs/providers/aws_sagemaker)  | βœ… | βœ… | βœ… | βœ… | βœ… |
| [aws - bedrock](https://docs.litellm.ai/docs/providers/bedrock)  | βœ… | βœ… | βœ… | βœ… |βœ… |
| [google - vertex_ai [Gemini]](https://docs.litellm.ai/docs/providers/vertex)  | βœ… | βœ… | βœ… | βœ… |
| [google - palm](https://docs.litellm.ai/docs/providers/palm)  | βœ… | βœ… | βœ… | βœ… |
| [google AI Studio - gemini](https://docs.litellm.ai/docs/providers/gemini)  | βœ… |  | βœ… |  | |
| [mistral ai api](https://docs.litellm.ai/docs/providers/mistral)  | βœ… | βœ… | βœ… | βœ… | βœ… |
| [cloudflare AI Workers](https://docs.litellm.ai/docs/providers/cloudflare_workers)  | βœ… | βœ… | βœ… | βœ… |
| [cohere](https://docs.litellm.ai/docs/providers/cohere)  | βœ… | βœ… | βœ… | βœ… | βœ… |
| [anthropic](https://docs.litellm.ai/docs/providers/anthropic)  | βœ… | βœ… | βœ… | βœ… |
| [huggingface](https://docs.litellm.ai/docs/providers/huggingface)  | βœ… | βœ… | βœ… | βœ… | βœ… |
| [replicate](https://docs.litellm.ai/docs/providers/replicate)  | βœ… | βœ… | βœ… | βœ… |
| [together_ai](https://docs.litellm.ai/docs/providers/togetherai)  | βœ… | βœ… | βœ… | βœ… |
| [openrouter](https://docs.litellm.ai/docs/providers/openrouter)  | βœ… | βœ… | βœ… | βœ… |
| [ai21](https://docs.litellm.ai/docs/providers/ai21)  | βœ… | βœ… | βœ… | βœ… |
| [baseten](https://docs.litellm.ai/docs/providers/baseten)  | βœ… | βœ… | βœ… | βœ… |
| [vllm](https://docs.litellm.ai/docs/providers/vllm)  | βœ… | βœ… | βœ… | βœ… |
| [nlp_cloud](https://docs.litellm.ai/docs/providers/nlp_cloud)  | βœ… | βœ… | βœ… | βœ… |
| [aleph alpha](https://docs.litellm.ai/docs/providers/aleph_alpha)  | βœ… | βœ… | βœ… | βœ… |
| [petals](https://docs.litellm.ai/docs/providers/petals)  | βœ… | βœ… | βœ… | βœ… |
| [ollama](https://docs.litellm.ai/docs/providers/ollama)  | βœ… | βœ… | βœ… | βœ… |
| [deepinfra](https://docs.litellm.ai/docs/providers/deepinfra)  | βœ… | βœ… | βœ… | βœ… |
| [perplexity-ai](https://docs.litellm.ai/docs/providers/perplexity)  | βœ… | βœ… | βœ… | βœ… |
| [Groq AI](https://docs.litellm.ai/docs/providers/groq)  | βœ… | βœ… | βœ… | βœ… |
| [anyscale](https://docs.litellm.ai/docs/providers/anyscale)  | βœ… | βœ… | βœ… | βœ… |
| [voyage ai](https://docs.litellm.ai/docs/providers/voyage)  |  |  |  |  | βœ… |
| [xinference [Xorbits Inference]](https://docs.litellm.ai/docs/providers/xinference)  |  |  |  |  | βœ… |

For more details, please visit the [litellm documentation](https://docs.litellm.ai/docs/providers).

You can easily build any third-party model calls using the following method:

```python
import promptulate as pne

resp: str = pne.chat(model="ollama/llama2", messages=[{"content": "Hello, how are you?", "role": "user"}])
```

## πŸ“— Related Documentation

- [Getting Started/Official Documentation](https://undertone0809.github.io/promptulate/#/)
- [Current Development Plan](https://undertone0809.github.io/promptulate/#/other/plan)
- [Contributing/Developer's Manual](https://undertone0809.github.io/promptulate/#/other/contribution)
- [Frequently Asked Questions](https://undertone0809.github.io/promptulate/#/other/faq)
- [PyPI Repository](https://pypi.org/project/promptulate/)

## πŸ›  Quick Start

- Open the terminal and enter the following command to install the framework:

```shell script
pip install -U promptulate  
```

> Note: Your Python version should be 3.8 or higher.

Robust output formatting is a fundamental basis for LLM application development. We hope that LLMs can return stable data. With pne, you can easily perform formatted output. In the following example, we use Pydantic's BaseModel to encapsulate a data structure that needs to be returned.

```python
from typing import List
import promptulate as pne
from pydantic import BaseModel, Field

class LLMResponse(BaseModel):
    provinces: List[str] = Field(description="List of provinces' names")

resp: LLMResponse = pne.chat("Please tell me all provinces in China.", output_schema=LLMResponse)
print(resp)
```

**Output:**

```text
provinces=['Anhui', 'Fujian', 'Gansu', 'Guangdong', 'Guizhou', 'Hainan', 'Hebei', 'Heilongjiang', 'Henan', 'Hubei', 'Hunan', 'Jiangsu', 'Jiangxi', 'Jilin', 'Liaoning', 'Qinghai', 'Shaanxi', 'Shandong', 'Shanxi', 'Sichuan', 'Yunnan', 'Zhejiang', 'Taiwan', 'Guangxi', 'Nei Mongol', 'Ningxia', 'Xinjiang', 'Xizang', 'Beijing', 'Chongqing', 'Shanghai', 'Tianjin', 'Hong Kong', 'Macao']
```

Additionally, influenced by the [Plan-and-Solve](https://arxiv.org/abs/2305.04091) paper, pne also allows developers to build Agents capable of dealing with complex problems through planning, reasoning, and action. The Agent's planning abilities can be activated using the `enable_plan` parameter.

![plan-and-execute.png](./docs/images/plan-and-execute.png)

In this example, we use [Tavily](https://app.tavily.com/) as the search engine, which is a powerful tool for searching information on the web. To use Tavily, you need to obtain an API key from Tavily.

```python
import os

os.environ["TAVILY_API_KEY"] = "your_tavily_api_key"
os.environ["OPENAI_API_KEY"] = "your_openai_api_key"
```

In this case, we are using the TavilySearchResults Tool wrapped by LangChain.

```python
from langchain_community.tools.tavily_search import TavilySearchResults

tools = [TavilySearchResults(max_results=5)]
```

```python
import promptulate as pne

pne.chat("what is the hometown of the 2024 Australia open winner?", model="gpt-4-1106-preview", enable_plan=True)
```

**Output:**

```text
[Agent] Assistant Agent start...
[User instruction] what is the hometown of the 2024 Australia open winner?
[Plan] {"goals": ["Find the hometown of the 2024 Australian Open winner"], "tasks": [{"task_id": 1, "description": "Identify the winner of the 2024 Australian Open."}, {"task_id": 2, "description": "Research the identified winner to find their place of birth or hometown."}, {"task_id": 3, "description": "Record the hometown of the 2024 Australian Open winner."}], "next_task_id": 1}
[Agent] Tool Agent start...
[User instruction] Identify the winner of the 2024 Australian Open.
[Thought] Since the current date is March 26, 2024, and the Australian Open typically takes place in January, the event has likely concluded for the year. To identify the winner, I should use the Tavily search tool to find the most recent information on the 2024 Australian Open winner.
[Action] tavily_search_results_json args: {'query': '2024 Australian Open winner'}
[Observation] [{'url': 'https://ausopen.com/articles/news/sinner-winner-italian-takes-first-major-ao-2024', 'content': 'The agile right-hander, who had claimed victory from a two-set deficit only once previously in his young career, is the second Italian man to achieve singles glory at a major, following Adriano Panatta in1976.With victories over Andrey Rublev, 10-time AO champion Novak Djokovic, and Medvedev, the Italian is the youngest player to defeat top 5 opponents in the final three matches of a major since Michael Stich did it at Wimbledon in 1991 – just weeks before Sinner was born.\n He saved the only break he faced with an ace down the tee, and helped by scoreboard pressure, broke Medvedev by slamming a huge forehand to force an error from his more experienced rival, sealing the fourth set to take the final to a decider.\n Sensing a shift in momentum as Medvedev served to close out the second at 5-3, Sinner set the RLA crowd alight with a pair of brilliant passing shots en route to creating a break point opportunity, which Medvedev snuffed out with trademark patience, drawing a forehand error from his opponent. β€œWe are trying to get better every day, even during the tournament we try to get stronger, trying to understand every situation a little bit better, and I’m so glad to have you there supporting me, understanding me, which sometimes it’s not easy because I am a little bit young sometimes,” he said with a smile.\n Medvedev, who held to love in his first three service games of the second set, piled pressure on the Italian, forcing the right-hander to produce his best tennis to save four break points in a nearly 12-minute second game.\n'}, {'url': 'https://www.cbssports.com/tennis/news/australian-open-2024-jannik-sinner-claims-first-grand-slam-title-in-epic-comeback-win-over-daniil-medvedev/', 'content': '"\nOur Latest Tennis Stories\nSinner makes epic comeback to win Australian Open\nSinner, Sabalenka win Australian Open singles titles\n2024 Australian Open odds, Sinner vs. Medvedev picks\nSabalenka defeats Zheng to win 2024 Australian Open\n2024 Australian Open odds, Sabalenka vs. Zheng picks\n2024 Australian Open odds, Medvedev vs. Zverev picks\nAustralian Open odds: Djokovic vs. Sinner picks, bets\nAustralian Open odds: Gauff vs. Sabalenka picks, bets\nAustralian Open odds: Zheng vs. Yastremska picks, bets\nNick Kyrgios reveals he\'s contemplating retirement\nΒ© 2004-2024 CBS Interactive. Jannik Sinner claims first Grand Slam title in epic comeback win over Daniil Medvedev\nSinner, 22, rallied back from a two-set deficit to become the third ever Italian Grand Slam men\'s singles champion\nAfter almost four hours, Jannik Sinner climbed back from a two-set deficit to win his first ever Grand Slam title with an epic 3-6, 3-6, 6-4, 6-4, 6-3 comeback victory against Daniil Medvedev. Sinner became the first Italian man to win the Australian Open since 1976, and just the eighth man to successfully come back from two sets down in a major final.\n He did not drop a single set until his meeting with Djokovic, and that win in itself was an accomplishment as Djokovic was riding a 33-match winning streak at the Australian Open and had never lost a semifinal in Melbourne.\n @janniksin β€’ @wwos β€’ @espn β€’ @eurosport β€’ @wowowtennis pic.twitter.com/DTCIqWoUoR\n"We are trying to get better everyday, and even during the tournament, trying to get stronger and understand the situation a little bit better," Sinner said.'}, {'url': 'https://www.bbc.com/sport/tennis/68120937', 'content': 'Live scores, results and order of play\nAlerts: Get tennis news sent to your phone\nRelated Topics\nTop Stories\nFA Cup: Blackburn Rovers v Wrexham - live text commentary\nRussian skater Valieva given four-year ban for doping\nLinks to Barcelona are \'totally untrue\' - Arteta\nElsewhere on the BBC\nThe truth behind the fake grooming scandal\nFeaturing unseen police footage and interviews with the officers at the heart of the case\nDid their father and uncle kill Nazi war criminals?\n A real-life murder mystery following three brothers in their quest for the truth\nWhat was it like to travel on the fastest plane?\nTake a behind-the-scenes look at the supersonic story of the Concorde\nToxic love, ruthless ambition and shocking betrayal\nTell Me Lies follows a passionate college relationship with unimaginable consequences...\n "\nMarathon man Medvedev runs out of steam\nMedvedev is the first player to lose two Grand Slam finals after winning the opening two sets\nSo many players with the experience of a Grand Slam final have talked about how different the occasion can be, particularly if it is the first time, and potentially overwhelming.\n Jannik Sinner beats Daniil Medvedev in Melbourne final\nJannik Sinner is the youngest player to win the Australian Open men\'s title since Novak Djokovic in 2008\nJannik Sinner landed the Grand Slam title he has long promised with an extraordinary fightback to beat Daniil Medvedev in the Australian Open final.\n "\nSinner starts 2024 in inspired form\nSinner won the first Australian Open men\'s final since 2005 which did not feature Roger Federer, Rafael Nadal or Novak Djokovic\nSinner was brought to the forefront of conversation when discussing Grand Slam champions in 2024 following a stunning end to last season.\n'}]
[Execute Result] {'thought': "The search results have provided consistent information about the winner of the 2024 Australian Open. Jannik Sinner is mentioned as the winner in multiple sources, which confirms the answer to the user's question.", 'action_name': 'finish', 'action_parameters': {'content': 'Jannik Sinner won the 2024 Australian Open.'}}
[Execute] Execute End.
[Revised Plan] {"goals": ["Find the hometown of the 2024 Australian Open winner"], "tasks": [{"task_id": 2, "description": "Research Jannik Sinner to find his place of birth or hometown."}, {"task_id": 3, "description": "Record the hometown of Jannik Sinner, the 2024 Australian Open winner."}], "next_task_id": 2}
[Agent] Tool Agent start...
[User instruction] Research Jannik Sinner to find his place of birth or hometown.
[Thought] To find Jannik Sinner's place of birth or hometown, I should use the search tool to find the most recent and accurate information.
[Action] tavily_search_results_json args: {'query': 'Jannik Sinner place of birth hometown'}
[Observation] [{'url': 'https://www.sportskeeda.com/tennis/jannik-sinner-nationality', 'content': "During the semifinal of the Cup, Sinner faced Djokovic for the third time in a row and became the first player to defeat him in a singles match. Jannik Sinner Nationality\nJannik Sinner is an Italian national and was born in Innichen, a town located in the mainly German-speaking area of South Tyrol in northern Italy. A. Jannik Sinner won his maiden Masters 1000 title at the 2023 Canadian Open defeating Alex de Minaur in the straight sets of the final.\n Apart from his glorious triumph at Melbourne Park in 2024, Jannik Sinner's best Grand Slam performance came at the 2023 Wimbledon, where he reached the semifinals. In 2020, Sinner became the youngest player since Novak Djokovic in 2006 to reach the quarter-finals of the French Open."}, {'url': 'https://en.wikipedia.org/wiki/Jannik_Sinner', 'content': "At the 2023 Australian Open, Sinner lost in the 4th round to eventual runner-up Stefanos Tsitsipas in 5 sets.[87]\nSinner then won his seventh title at the Open Sud de France in Montpellier, becoming the first player to win a tour-level title in the season without having dropped a single set and the first since countryman Lorenzo Musetti won the title in Naples in October 2022.[88]\nAt the ABN AMRO Open he defeated top seed and world No. 3 Stefanos Tsitsipas taking his revenge for the Australian Open loss, for his biggest win ever.[89] At the Cincinnati Masters, he lost in the third round to FΓ©lix Auger-Aliassime after being up a set, a break, and 2 match points.[76]\nSeeded 11th at the US Open, he reached the fourth round after defeating Brandon Nakashima in four sets.[77] Next, he defeated Ilya Ivashka in a five set match lasting close to four hours to reach the quarterfinals for the first time at this Major.[78] At five hours and 26 minutes, it was the longest match of Sinner's career up until this point and the fifth-longest in the tournament history[100] as well as the second longest of the season after Andy Murray against Thanasi Kokkinakis at the Australian Open.[101]\nHe reached back to back quarterfinals in Wimbledon after defeating Juan Manuel Cerundolo, Diego Schwartzman, Quentin Halys and Daniel Elahi Galan.[102] He then reached his first Major semifinal after defeating Roman Safiullin, before losing to Novak Djokovic in straight sets.[103] In the following round in the semifinals, he lost in straight sets to career rival and top seed Carlos Alcaraz who returned to world No. 1 following the tournament.[92] In Miami, he reached the quarterfinals of this tournament for a third straight year after defeating Grigor Dimitrov and Andrey Rublev, thus returning to the top 10 in the rankings at world No. In the final, he came from a two-set deficit to beat Daniil Medvedev to become the first Italian player, male or female, to win the Australian Open singles title, and the third man to win a Major (the second of which is in the Open Era), the first in 48 years.[8][122]"}, {'url': 'https://www.thesportreview.com/biography/jannik-sinner/', 'content': 'Ò€’ Date of birth: 16 August 2001\nÒ€’ Age: 22 years old\nÒ€’ Place of birth: San Candido, Italy\nÒ€’ Nationality: Italian\nÒ€’ Height: 188cm / 6ft 2ins\nÒ€’ Weight: 76kg / 167lbs\nÒ€’ Plays: Right-handed\nÒ€’ Turned Pro: 2018\nÒ€’ Career Prize Money: US$ 4,896,338\nÒ€’ Instagram: @janniksin\nThe impressive 22-year-old turned professional back in 2018 and soon made an impact on the tour, breaking into the top 100 in the world rankings for the first time in 2019.\n Jannik Sinner (Photo: Dubai Duty Free Tennis Championships)\nSinner ended the season as number 78 in the world, becoming the youngest player since Rafael Nadal in 2003 to end the year in the top 80.\n The Italian then ended the 2019 season in style, qualifying for the 2019 Next Gen ATP Finals and going on to win the tournament with a win over Alex de Minaur in the final.\n Sinner then reached the main draw of a grand slam for the first time at the 2019 US Open, when he came through qualifying to reach the first round, where he lost to Stan Wawrinka.\n Asked to acknowledge some of the key figures in his development, Sinner replied: β€œI think first of all, my family who always helped me and gave me the confidence to actually change my life when I was 13-and-a-half, 14 years old.\n'}]
[Execute Result] {'thought': 'The search results have provided two different places of birth for Jannik Sinner: Innichen and San Candido. These are actually the same place, as San Candido is the Italian name and Innichen is the German name for the town. Since the user asked for the place of birth or hometown, I can now provide this information.', 'action_name': 'finish', 'action_parameters': {'content': 'Jannik Sinner was born in San Candido (Italian) / Innichen (German), Italy.'}}
[Execute] Execute End.
[Revised Plan] {"goals": ["Find the hometown of the 2024 Australian Open winner"], "tasks": [], "next_task_id": null}
[Agent Result] Jannik Sinner was born in San Candido (Italian) / Innichen (German), Italy.
[Agent] Agent End.
```

For more detailed information, please check the [Getting Started/Official Documentation](https://undertone0809.github.io/promptulate/#/).

## πŸ“š Design Principles

The design principles of the pne framework include modularity, extensibility, interoperability, robustness, maintainability, security, efficiency, and usability.

- Modularity refers to using modules as the basic unit, allowing for easy integration of new components, models, and tools.
- Extensibility refers to the framework's ability to handle large amounts of data, complex tasks, and high concurrency.
- Interoperability means the framework is compatible with various external systems, tools, and services and can achieve seamless integration and communication.
- Robustness indicates the framework has strong error handling, fault tolerance, and recovery mechanisms to ensure reliable operation under various conditions.
- Security implies the framework has implemented strict measures to protect against unauthorized access and malicious behavior.
- Efficiency is about optimizing the framework's performance, resource usage, and response times to ensure a smooth and responsive user experience.
- Usability means the framework uses user-friendly interfaces and clear documentation, making it easy to use and understand.

Following these principles and applying the latest artificial intelligence technologies, `pne` aims to provide a powerful and flexible framework for creating automated agents.

## πŸ’Œ Contact

For more information, please contact: [zeeland4work@gmail.com](mailto:zeeland4work@gmail.com)

## ⭐ Contribution

We appreciate your interest in contributing to our open-source initiative. We have provided a [Developer's Guide](https://undertone0809.github.io/promptulate/#/other/contribution) outlining the steps to contribute to Promptulate. Please refer to this guide to ensure smooth collaboration and successful contributions. Additionally, you can view the [Current Development Plan](https://undertone0809.github.io/promptulate/#/other/plan) to see the latest development progress πŸ€πŸš€

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/Undertone0809/promptulate",
    "name": "promptulate",
    "maintainer": null,
    "docs_url": null,
    "requires_python": "<4.0,>=3.8.1",
    "maintainer_email": null,
    "keywords": "promptulate, pne, prompt, agent, openai, chatgpt, gpt, llm, openai, langchain, litellm",
    "author": "Zeeland",
    "author_email": "zeeland4work@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/d5/1a/5a9f580c5995fc4f72fb2041ba9b2e29af68c18713b08954f7b7c4596c22/promptulate-1.15.3.tar.gz",
    "platform": null,
    "description": "<h1 align=\"center\">\n    Promptulate\n</h1>\n\n<p align=\"center\">\n    <a target=\"_blank\" href=\"\">\n        <img src=\"https://img.shields.io/github/license/Undertone0809/promptulate.svg?style=flat-square\" />\n    </a>\n    <a target=\"_blank\" href=''>\n        <img src=\"https://img.shields.io/github/release/Undertone0809/promptulate/all.svg?style=flat-square\"/>\n    </a>\n    <a target=\"_blank\" href=''>\n        <img src=\"https://bestpractices.coreinfrastructure.org/projects/3018/badge\"/>\n   </a>\n    <a target=\"_blank\" href=''>\n        <img src=\"https://static.pepy.tech/personalized-badge/promptulate?period=month&units=international_system&left_color=grey&right_color=blue&left_text=Downloads/Week\"/>\n    </a>\n    <a target=\"_blank\" href=''>\n        <img src=\"docs/images/coverage.svg\"/>\n    </a>\n</p>\n\n[English](/README.md) [\u4e2d\u6587](/README_zh.md)\n\n<p align=\"center\">\n  <img src=\"https://zeeland-bucket.oss-cn-beijing.aliyuncs.com/images/promptulate_logo_new.png\"/>\n</p>\n\n## Overview\n\n**Promptulate** is an AI Agent application development framework crafted by **Cogit Lab**, which offers developers an extremely concise and efficient way to build Agent applications through a Pythonic development paradigm. The core philosophy of Promptulate is to borrow and integrate the wisdom of the open-source community, incorporating the highlights of various development frameworks to lower the barrier to entry and unify the consensus among developers. With Promptulate, you can manipulate components like LLM, Agent, Tool, RAG, etc., with the most succinct code, as most tasks can be easily completed with just a few lines of code. \ud83d\ude80\n\n## \ud83d\udca1 Features\n\n- \ud83d\udc0d Pythonic Code Style: Embraces the habits of Python developers, providing a Pythonic SDK calling approach, putting everything within your grasp with just one `pne.chat` function to encapsulate all essential functionalities.\n- \ud83e\udde0 Model Compatibility: Supports nearly all types of large models on the market and allows for easy customization to meet specific needs.\n- \ud83d\udd75\ufe0f\u200d\u2642\ufe0f Diverse Agents: Offers various types of Agents, such as WebAgent, ToolAgent, CodeAgent, etc., capable of planning, reasoning, and acting to handle complex problems.\n- \ud83d\udd17 Low-Cost Integration: Effortlessly integrates tools from different frameworks like LangChain, significantly reducing integration costs.\n- \ud83d\udd28 Functions as Tools: Converts any Python function directly into a tool usable by Agents, simplifying the tool creation and usage process.\n- \ud83e\ude9d Lifecycle and Hooks: Provides a wealth of Hooks and comprehensive lifecycle management, allowing the insertion of custom code at various stages of Agents, Tools, and LLMs.\n- \ud83d\udcbb Terminal Integration: Easily integrates application terminals, with built-in client support, offering rapid debugging capabilities for prompts.\n- \u23f1\ufe0f Prompt Caching: Offers a caching mechanism for LLM Prompts to reduce repetitive work and enhance development efficiency.\n\n> Below, `pne` stands for Promptulate, which is the nickname for Promptulate. The `p` and `e` represent the beginning and end of Promptulate, respectively, and `n` stands for 9, which is a shorthand for the nine letters between `p` and `e`.\n\n## Supported Base Models\n\nPromptulate integrates the capabilities of [litellm](https://github.com/BerriAI/litellm), supporting nearly all types of large models on the market, including but not limited to the following models:\n\n| Provider      | [Completion](https://docs.litellm.ai/docs/#basic-usage) | [Streaming](https://docs.litellm.ai/docs/completion/stream#streaming-responses)  | [Async Completion](https://docs.litellm.ai/docs/completion/stream#async-completion)  | [Async Streaming](https://docs.litellm.ai/docs/completion/stream#async-streaming)  | [Async Embedding](https://docs.litellm.ai/docs/embedding/supported_embedding)  | [Async Image Generation](https://docs.litellm.ai/docs/image_generation)  | \n| ------------- | ------------- | ------------- | ------------- | ------------- | ------------- | ------------- |\n| [openai](https://docs.litellm.ai/docs/providers/openai)  | \u2705 | \u2705 | \u2705 | \u2705 | \u2705 | \u2705 |\n| [azure](https://docs.litellm.ai/docs/providers/azure)  | \u2705 | \u2705 | \u2705 | \u2705 | \u2705 | \u2705 |\n| [aws - sagemaker](https://docs.litellm.ai/docs/providers/aws_sagemaker)  | \u2705 | \u2705 | \u2705 | \u2705 | \u2705 |\n| [aws - bedrock](https://docs.litellm.ai/docs/providers/bedrock)  | \u2705 | \u2705 | \u2705 | \u2705 |\u2705 |\n| [google - vertex_ai [Gemini]](https://docs.litellm.ai/docs/providers/vertex)  | \u2705 | \u2705 | \u2705 | \u2705 |\n| [google - palm](https://docs.litellm.ai/docs/providers/palm)  | \u2705 | \u2705 | \u2705 | \u2705 |\n| [google AI Studio - gemini](https://docs.litellm.ai/docs/providers/gemini)  | \u2705 |  | \u2705 |  | |\n| [mistral ai api](https://docs.litellm.ai/docs/providers/mistral)  | \u2705 | \u2705 | \u2705 | \u2705 | \u2705 |\n| [cloudflare AI Workers](https://docs.litellm.ai/docs/providers/cloudflare_workers)  | \u2705 | \u2705 | \u2705 | \u2705 |\n| [cohere](https://docs.litellm.ai/docs/providers/cohere)  | \u2705 | \u2705 | \u2705 | \u2705 | \u2705 |\n| [anthropic](https://docs.litellm.ai/docs/providers/anthropic)  | \u2705 | \u2705 | \u2705 | \u2705 |\n| [huggingface](https://docs.litellm.ai/docs/providers/huggingface)  | \u2705 | \u2705 | \u2705 | \u2705 | \u2705 |\n| [replicate](https://docs.litellm.ai/docs/providers/replicate)  | \u2705 | \u2705 | \u2705 | \u2705 |\n| [together_ai](https://docs.litellm.ai/docs/providers/togetherai)  | \u2705 | \u2705 | \u2705 | \u2705 |\n| [openrouter](https://docs.litellm.ai/docs/providers/openrouter)  | \u2705 | \u2705 | \u2705 | \u2705 |\n| [ai21](https://docs.litellm.ai/docs/providers/ai21)  | \u2705 | \u2705 | \u2705 | \u2705 |\n| [baseten](https://docs.litellm.ai/docs/providers/baseten)  | \u2705 | \u2705 | \u2705 | \u2705 |\n| [vllm](https://docs.litellm.ai/docs/providers/vllm)  | \u2705 | \u2705 | \u2705 | \u2705 |\n| [nlp_cloud](https://docs.litellm.ai/docs/providers/nlp_cloud)  | \u2705 | \u2705 | \u2705 | \u2705 |\n| [aleph alpha](https://docs.litellm.ai/docs/providers/aleph_alpha)  | \u2705 | \u2705 | \u2705 | \u2705 |\n| [petals](https://docs.litellm.ai/docs/providers/petals)  | \u2705 | \u2705 | \u2705 | \u2705 |\n| [ollama](https://docs.litellm.ai/docs/providers/ollama)  | \u2705 | \u2705 | \u2705 | \u2705 |\n| [deepinfra](https://docs.litellm.ai/docs/providers/deepinfra)  | \u2705 | \u2705 | \u2705 | \u2705 |\n| [perplexity-ai](https://docs.litellm.ai/docs/providers/perplexity)  | \u2705 | \u2705 | \u2705 | \u2705 |\n| [Groq AI](https://docs.litellm.ai/docs/providers/groq)  | \u2705 | \u2705 | \u2705 | \u2705 |\n| [anyscale](https://docs.litellm.ai/docs/providers/anyscale)  | \u2705 | \u2705 | \u2705 | \u2705 |\n| [voyage ai](https://docs.litellm.ai/docs/providers/voyage)  |  |  |  |  | \u2705 |\n| [xinference [Xorbits Inference]](https://docs.litellm.ai/docs/providers/xinference)  |  |  |  |  | \u2705 |\n\nFor more details, please visit the [litellm documentation](https://docs.litellm.ai/docs/providers).\n\nYou can easily build any third-party model calls using the following method:\n\n```python\nimport promptulate as pne\n\nresp: str = pne.chat(model=\"ollama/llama2\", messages=[{\"content\": \"Hello, how are you?\", \"role\": \"user\"}])\n```\n\n## \ud83d\udcd7 Related Documentation\n\n- [Getting Started/Official Documentation](https://undertone0809.github.io/promptulate/#/)\n- [Current Development Plan](https://undertone0809.github.io/promptulate/#/other/plan)\n- [Contributing/Developer's Manual](https://undertone0809.github.io/promptulate/#/other/contribution)\n- [Frequently Asked Questions](https://undertone0809.github.io/promptulate/#/other/faq)\n- [PyPI Repository](https://pypi.org/project/promptulate/)\n\n## \ud83d\udee0 Quick Start\n\n- Open the terminal and enter the following command to install the framework:\n\n```shell script\npip install -U promptulate  \n```\n\n> Note: Your Python version should be 3.8 or higher.\n\nRobust output formatting is a fundamental basis for LLM application development. We hope that LLMs can return stable data. With pne, you can easily perform formatted output. In the following example, we use Pydantic's BaseModel to encapsulate a data structure that needs to be returned.\n\n```python\nfrom typing import List\nimport promptulate as pne\nfrom pydantic import BaseModel, Field\n\nclass LLMResponse(BaseModel):\n    provinces: List[str] = Field(description=\"List of provinces' names\")\n\nresp: LLMResponse = pne.chat(\"Please tell me all provinces in China.\", output_schema=LLMResponse)\nprint(resp)\n```\n\n**Output:**\n\n```text\nprovinces=['Anhui', 'Fujian', 'Gansu', 'Guangdong', 'Guizhou', 'Hainan', 'Hebei', 'Heilongjiang', 'Henan', 'Hubei', 'Hunan', 'Jiangsu', 'Jiangxi', 'Jilin', 'Liaoning', 'Qinghai', 'Shaanxi', 'Shandong', 'Shanxi', 'Sichuan', 'Yunnan', 'Zhejiang', 'Taiwan', 'Guangxi', 'Nei Mongol', 'Ningxia', 'Xinjiang', 'Xizang', 'Beijing', 'Chongqing', 'Shanghai', 'Tianjin', 'Hong Kong', 'Macao']\n```\n\nAdditionally, influenced by the [Plan-and-Solve](https://arxiv.org/abs/2305.04091) paper, pne also allows developers to build Agents capable of dealing with complex problems through planning, reasoning, and action. The Agent's planning abilities can be activated using the `enable_plan` parameter.\n\n![plan-and-execute.png](./docs/images/plan-and-execute.png)\n\nIn this example, we use [Tavily](https://app.tavily.com/) as the search engine, which is a powerful tool for searching information on the web. To use Tavily, you need to obtain an API key from Tavily.\n\n```python\nimport os\n\nos.environ[\"TAVILY_API_KEY\"] = \"your_tavily_api_key\"\nos.environ[\"OPENAI_API_KEY\"] = \"your_openai_api_key\"\n```\n\nIn this case, we are using the TavilySearchResults Tool wrapped by LangChain.\n\n```python\nfrom langchain_community.tools.tavily_search import TavilySearchResults\n\ntools = [TavilySearchResults(max_results=5)]\n```\n\n```python\nimport promptulate as pne\n\npne.chat(\"what is the hometown of the 2024 Australia open winner?\", model=\"gpt-4-1106-preview\", enable_plan=True)\n```\n\n**Output:**\n\n```text\n[Agent] Assistant Agent start...\n[User instruction] what is the hometown of the 2024 Australia open winner?\n[Plan] {\"goals\": [\"Find the hometown of the 2024 Australian Open winner\"], \"tasks\": [{\"task_id\": 1, \"description\": \"Identify the winner of the 2024 Australian Open.\"}, {\"task_id\": 2, \"description\": \"Research the identified winner to find their place of birth or hometown.\"}, {\"task_id\": 3, \"description\": \"Record the hometown of the 2024 Australian Open winner.\"}], \"next_task_id\": 1}\n[Agent] Tool Agent start...\n[User instruction] Identify the winner of the 2024 Australian Open.\n[Thought] Since the current date is March 26, 2024, and the Australian Open typically takes place in January, the event has likely concluded for the year. To identify the winner, I should use the Tavily search tool to find the most recent information on the 2024 Australian Open winner.\n[Action] tavily_search_results_json args: {'query': '2024 Australian Open winner'}\n[Observation] [{'url': 'https://ausopen.com/articles/news/sinner-winner-italian-takes-first-major-ao-2024', 'content': 'The agile right-hander, who had claimed victory from a two-set deficit only once previously in his young career, is the second Italian man to achieve singles glory at a major, following Adriano Panatta in1976.With victories over Andrey Rublev, 10-time AO champion Novak Djokovic, and Medvedev, the Italian is the youngest player to defeat top 5 opponents in the final three matches of a major since Michael Stich did it at Wimbledon in 1991 \u2013 just weeks before Sinner was born.\\n He saved the only break he faced with an ace down the tee, and helped by scoreboard pressure, broke Medvedev by slamming a huge forehand to force an error from his more experienced rival, sealing the fourth set to take the final to a decider.\\n Sensing a shift in momentum as Medvedev served to close out the second at 5-3, Sinner set the RLA crowd alight with a pair of brilliant passing shots en route to creating a break point opportunity, which Medvedev snuffed out with trademark patience, drawing a forehand error from his opponent. \u201cWe are trying to get better every day, even during the tournament we try to get stronger, trying to understand every situation a little bit better, and I\u2019m so glad to have you there supporting me, understanding me, which sometimes it\u2019s not easy because I am a little bit young sometimes,\u201d he said with a smile.\\n Medvedev, who held to love in his first three service games of the second set, piled pressure on the Italian, forcing the right-hander to produce his best tennis to save four break points in a nearly 12-minute second game.\\n'}, {'url': 'https://www.cbssports.com/tennis/news/australian-open-2024-jannik-sinner-claims-first-grand-slam-title-in-epic-comeback-win-over-daniil-medvedev/', 'content': '\"\\nOur Latest Tennis Stories\\nSinner makes epic comeback to win Australian Open\\nSinner, Sabalenka win Australian Open singles titles\\n2024 Australian Open odds, Sinner vs. Medvedev picks\\nSabalenka defeats Zheng to win 2024 Australian Open\\n2024 Australian Open odds, Sabalenka vs. Zheng picks\\n2024 Australian Open odds, Medvedev vs. Zverev picks\\nAustralian Open odds: Djokovic vs. Sinner picks, bets\\nAustralian Open odds: Gauff vs. Sabalenka picks, bets\\nAustralian Open odds: Zheng vs. Yastremska picks, bets\\nNick Kyrgios reveals he\\'s contemplating retirement\\n\u00a9 2004-2024 CBS Interactive. Jannik Sinner claims first Grand Slam title in epic comeback win over Daniil Medvedev\\nSinner, 22, rallied back from a two-set deficit to become the third ever Italian Grand Slam men\\'s singles champion\\nAfter almost four hours, Jannik Sinner climbed back from a two-set deficit to win his first ever Grand Slam title with an epic 3-6, 3-6, 6-4, 6-4, 6-3 comeback victory against Daniil Medvedev. Sinner became the first Italian man to win the Australian Open since 1976, and just the eighth man to successfully come back from two sets down in a major final.\\n He did not drop a single set until his meeting with Djokovic, and that win in itself was an accomplishment as Djokovic was riding a 33-match winning streak at the Australian Open and had never lost a semifinal in Melbourne.\\n @janniksin \u2022 @wwos \u2022 @espn \u2022 @eurosport \u2022 @wowowtennis pic.twitter.com/DTCIqWoUoR\\n\"We are trying to get better everyday, and even during the tournament, trying to get stronger and understand the situation a little bit better,\" Sinner said.'}, {'url': 'https://www.bbc.com/sport/tennis/68120937', 'content': 'Live scores, results and order of play\\nAlerts: Get tennis news sent to your phone\\nRelated Topics\\nTop Stories\\nFA Cup: Blackburn Rovers v Wrexham - live text commentary\\nRussian skater Valieva given four-year ban for doping\\nLinks to Barcelona are \\'totally untrue\\' - Arteta\\nElsewhere on the BBC\\nThe truth behind the fake grooming scandal\\nFeaturing unseen police footage and interviews with the officers at the heart of the case\\nDid their father and uncle kill Nazi war criminals?\\n A real-life murder mystery following three brothers in their quest for the truth\\nWhat was it like to travel on the fastest plane?\\nTake a behind-the-scenes look at the supersonic story of the Concorde\\nToxic love, ruthless ambition and shocking betrayal\\nTell Me Lies follows a passionate college relationship with unimaginable consequences...\\n \"\\nMarathon man Medvedev runs out of steam\\nMedvedev is the first player to lose two Grand Slam finals after winning the opening two sets\\nSo many players with the experience of a Grand Slam final have talked about how different the occasion can be, particularly if it is the first time, and potentially overwhelming.\\n Jannik Sinner beats Daniil Medvedev in Melbourne final\\nJannik Sinner is the youngest player to win the Australian Open men\\'s title since Novak Djokovic in 2008\\nJannik Sinner landed the Grand Slam title he has long promised with an extraordinary fightback to beat Daniil Medvedev in the Australian Open final.\\n \"\\nSinner starts 2024 in inspired form\\nSinner won the first Australian Open men\\'s final since 2005 which did not feature Roger Federer, Rafael Nadal or Novak Djokovic\\nSinner was brought to the forefront of conversation when discussing Grand Slam champions in 2024 following a stunning end to last season.\\n'}]\n[Execute Result] {'thought': \"The search results have provided consistent information about the winner of the 2024 Australian Open. Jannik Sinner is mentioned as the winner in multiple sources, which confirms the answer to the user's question.\", 'action_name': 'finish', 'action_parameters': {'content': 'Jannik Sinner won the 2024 Australian Open.'}}\n[Execute] Execute End.\n[Revised Plan] {\"goals\": [\"Find the hometown of the 2024 Australian Open winner\"], \"tasks\": [{\"task_id\": 2, \"description\": \"Research Jannik Sinner to find his place of birth or hometown.\"}, {\"task_id\": 3, \"description\": \"Record the hometown of Jannik Sinner, the 2024 Australian Open winner.\"}], \"next_task_id\": 2}\n[Agent] Tool Agent start...\n[User instruction] Research Jannik Sinner to find his place of birth or hometown.\n[Thought] To find Jannik Sinner's place of birth or hometown, I should use the search tool to find the most recent and accurate information.\n[Action] tavily_search_results_json args: {'query': 'Jannik Sinner place of birth hometown'}\n[Observation] [{'url': 'https://www.sportskeeda.com/tennis/jannik-sinner-nationality', 'content': \"During the semifinal of the Cup, Sinner faced Djokovic for the third time in a row and became the first player to defeat him in a singles match. Jannik Sinner Nationality\\nJannik Sinner is an Italian national and was born in Innichen, a town located in the mainly German-speaking area of South Tyrol in northern Italy. A. Jannik Sinner won his maiden Masters 1000 title at the 2023 Canadian Open defeating Alex de Minaur in the straight sets of the final.\\n Apart from his glorious triumph at Melbourne Park in 2024, Jannik Sinner's best Grand Slam performance came at the 2023 Wimbledon, where he reached the semifinals. In 2020, Sinner became the youngest player since Novak Djokovic in 2006 to reach the quarter-finals of the French Open.\"}, {'url': 'https://en.wikipedia.org/wiki/Jannik_Sinner', 'content': \"At the 2023 Australian Open, Sinner lost in the 4th round to eventual runner-up Stefanos Tsitsipas in 5 sets.[87]\\nSinner then won his seventh title at the Open Sud de France in Montpellier, becoming the first player to win a tour-level title in the season without having dropped a single set and the first since countryman Lorenzo Musetti won the title in Naples in October 2022.[88]\\nAt the ABN AMRO Open he defeated top seed and world No. 3 Stefanos Tsitsipas taking his revenge for the Australian Open loss, for his biggest win ever.[89] At the Cincinnati Masters, he lost in the third round to F\u00e9lix Auger-Aliassime after being up a set, a break, and 2 match points.[76]\\nSeeded 11th at the US Open, he reached the fourth round after defeating Brandon Nakashima in four sets.[77] Next, he defeated Ilya Ivashka in a five set match lasting close to four hours to reach the quarterfinals for the first time at this Major.[78] At five hours and 26 minutes, it was the longest match of Sinner's career up until this point and the fifth-longest in the tournament history[100] as well as the second longest of the season after Andy Murray against Thanasi Kokkinakis at the Australian Open.[101]\\nHe reached back to back quarterfinals in Wimbledon after defeating Juan Manuel Cerundolo, Diego Schwartzman, Quentin Halys and Daniel Elahi Galan.[102] He then reached his first Major semifinal after defeating Roman Safiullin, before losing to Novak Djokovic in straight sets.[103] In the following round in the semifinals, he lost in straight sets to career rival and top seed Carlos Alcaraz who returned to world No. 1 following the tournament.[92] In Miami, he reached the quarterfinals of this tournament for a third straight year after defeating Grigor Dimitrov and Andrey Rublev, thus returning to the top 10 in the rankings at world No. In the final, he came from a two-set deficit to beat Daniil Medvedev to become the first Italian player, male or female, to win the Australian Open singles title, and the third man to win a Major (the second of which is in the Open Era), the first in 48 years.[8][122]\"}, {'url': 'https://www.thesportreview.com/biography/jannik-sinner/', 'content': '\u00e2\u20ac\u00a2 Date of birth: 16 August 2001\\n\u00e2\u20ac\u00a2 Age: 22 years old\\n\u00e2\u20ac\u00a2 Place of birth: San Candido, Italy\\n\u00e2\u20ac\u00a2 Nationality: Italian\\n\u00e2\u20ac\u00a2 Height: 188cm / 6ft 2ins\\n\u00e2\u20ac\u00a2 Weight: 76kg / 167lbs\\n\u00e2\u20ac\u00a2 Plays: Right-handed\\n\u00e2\u20ac\u00a2 Turned Pro: 2018\\n\u00e2\u20ac\u00a2 Career Prize Money: US$ 4,896,338\\n\u00e2\u20ac\u00a2 Instagram: @janniksin\\nThe impressive 22-year-old turned professional back in 2018 and soon made an impact on the tour, breaking into the top 100 in the world rankings for the first time in 2019.\\n Jannik Sinner (Photo: Dubai Duty Free Tennis Championships)\\nSinner ended the season as number 78 in the world, becoming the youngest player since Rafael Nadal in 2003 to end the year in the top 80.\\n The Italian then ended the 2019 season in style, qualifying for the 2019 Next Gen ATP Finals and going on to win the tournament with a win over Alex de Minaur in the final.\\n Sinner then reached the main draw of a grand slam for the first time at the 2019 US Open, when he came through qualifying to reach the first round, where he lost to Stan Wawrinka.\\n Asked to acknowledge some of the key figures in his development, Sinner replied: \u201cI think first of all, my family who always helped me and gave me the confidence to actually change my life when I was 13-and-a-half, 14 years old.\\n'}]\n[Execute Result] {'thought': 'The search results have provided two different places of birth for Jannik Sinner: Innichen and San Candido. These are actually the same place, as San Candido is the Italian name and Innichen is the German name for the town. Since the user asked for the place of birth or hometown, I can now provide this information.', 'action_name': 'finish', 'action_parameters': {'content': 'Jannik Sinner was born in San Candido (Italian) / Innichen (German), Italy.'}}\n[Execute] Execute End.\n[Revised Plan] {\"goals\": [\"Find the hometown of the 2024 Australian Open winner\"], \"tasks\": [], \"next_task_id\": null}\n[Agent Result] Jannik Sinner was born in San Candido (Italian) / Innichen (German), Italy.\n[Agent] Agent End.\n```\n\nFor more detailed information, please check the [Getting Started/Official Documentation](https://undertone0809.github.io/promptulate/#/).\n\n## \ud83d\udcda Design Principles\n\nThe design principles of the pne framework include modularity, extensibility, interoperability, robustness, maintainability, security, efficiency, and usability.\n\n- Modularity refers to using modules as the basic unit, allowing for easy integration of new components, models, and tools.\n- Extensibility refers to the framework's ability to handle large amounts of data, complex tasks, and high concurrency.\n- Interoperability means the framework is compatible with various external systems, tools, and services and can achieve seamless integration and communication.\n- Robustness indicates the framework has strong error handling, fault tolerance, and recovery mechanisms to ensure reliable operation under various conditions.\n- Security implies the framework has implemented strict measures to protect against unauthorized access and malicious behavior.\n- Efficiency is about optimizing the framework's performance, resource usage, and response times to ensure a smooth and responsive user experience.\n- Usability means the framework uses user-friendly interfaces and clear documentation, making it easy to use and understand.\n\nFollowing these principles and applying the latest artificial intelligence technologies, `pne` aims to provide a powerful and flexible framework for creating automated agents.\n\n## \ud83d\udc8c Contact\n\nFor more information, please contact: [zeeland4work@gmail.com](mailto:zeeland4work@gmail.com)\n\n## \u2b50 Contribution\n\nWe appreciate your interest in contributing to our open-source initiative. We have provided a [Developer's Guide](https://undertone0809.github.io/promptulate/#/other/contribution) outlining the steps to contribute to Promptulate. Please refer to this guide to ensure smooth collaboration and successful contributions. Additionally, you can view the [Current Development Plan](https://undertone0809.github.io/promptulate/#/other/plan) to see the latest development progress \ud83e\udd1d\ud83d\ude80\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "A powerful LLM Application development framework.",
    "version": "1.15.3",
    "project_urls": {
        "Homepage": "https://github.com/Undertone0809/promptulate",
        "Repository": "https://github.com/Undertone0809/promptulate"
    },
    "split_keywords": [
        "promptulate",
        " pne",
        " prompt",
        " agent",
        " openai",
        " chatgpt",
        " gpt",
        " llm",
        " openai",
        " langchain",
        " litellm"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f1946360bf691b1150700ae50ae64899664c7ab559b7073d26963a00cd5de1b6",
                "md5": "025f04e41675591ad9ea3431bfbf9aa4",
                "sha256": "1ce1109031c678b67a585e29013af3bfe4f2ef9f4c5170fc03c053c2d92c090a"
            },
            "downloads": -1,
            "filename": "promptulate-1.15.3-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "025f04e41675591ad9ea3431bfbf9aa4",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<4.0,>=3.8.1",
            "size": 130521,
            "upload_time": "2024-04-23T13:49:52",
            "upload_time_iso_8601": "2024-04-23T13:49:52.900846Z",
            "url": "https://files.pythonhosted.org/packages/f1/94/6360bf691b1150700ae50ae64899664c7ab559b7073d26963a00cd5de1b6/promptulate-1.15.3-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "d51a5a9f580c5995fc4f72fb2041ba9b2e29af68c18713b08954f7b7c4596c22",
                "md5": "53a2972e943997d88d33a6f06cfdc701",
                "sha256": "abcf30b6d7e7887ca5edba9dfd6fdfcde5a8883f54f63bae3edc4acbf44eab20"
            },
            "downloads": -1,
            "filename": "promptulate-1.15.3.tar.gz",
            "has_sig": false,
            "md5_digest": "53a2972e943997d88d33a6f06cfdc701",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<4.0,>=3.8.1",
            "size": 93877,
            "upload_time": "2024-04-23T13:49:54",
            "upload_time_iso_8601": "2024-04-23T13:49:54.416398Z",
            "url": "https://files.pythonhosted.org/packages/d5/1a/5a9f580c5995fc4f72fb2041ba9b2e29af68c18713b08954f7b7c4596c22/promptulate-1.15.3.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-04-23 13:49:54",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "Undertone0809",
    "github_project": "promptulate",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "requirements": [
        {
            "name": "aiohttp",
            "specs": [
                [
                    "==",
                    "3.9.3"
                ]
            ]
        },
        {
            "name": "aiosignal",
            "specs": [
                [
                    "==",
                    "1.3.1"
                ]
            ]
        },
        {
            "name": "annotated-types",
            "specs": [
                [
                    "==",
                    "0.6.0"
                ]
            ]
        },
        {
            "name": "anyio",
            "specs": [
                [
                    "==",
                    "4.3.0"
                ]
            ]
        },
        {
            "name": "async-timeout",
            "specs": [
                [
                    "==",
                    "4.0.3"
                ]
            ]
        },
        {
            "name": "attrs",
            "specs": [
                [
                    "==",
                    "23.2.0"
                ]
            ]
        },
        {
            "name": "broadcast-service",
            "specs": [
                [
                    "==",
                    "1.3.2"
                ]
            ]
        },
        {
            "name": "certifi",
            "specs": [
                [
                    "==",
                    "2024.2.2"
                ]
            ]
        },
        {
            "name": "charset-normalizer",
            "specs": [
                [
                    "==",
                    "3.3.2"
                ]
            ]
        },
        {
            "name": "click",
            "specs": [
                [
                    "==",
                    "8.1.7"
                ]
            ]
        },
        {
            "name": "colorama",
            "specs": [
                [
                    "==",
                    "0.4.6"
                ]
            ]
        },
        {
            "name": "cushy-storage",
            "specs": [
                [
                    "==",
                    "1.3.7"
                ]
            ]
        },
        {
            "name": "distro",
            "specs": [
                [
                    "==",
                    "1.9.0"
                ]
            ]
        },
        {
            "name": "exceptiongroup",
            "specs": [
                [
                    "==",
                    "1.2.0"
                ]
            ]
        },
        {
            "name": "filelock",
            "specs": [
                [
                    "==",
                    "3.13.2"
                ]
            ]
        },
        {
            "name": "frozenlist",
            "specs": [
                [
                    "==",
                    "1.4.1"
                ]
            ]
        },
        {
            "name": "fsspec",
            "specs": [
                [
                    "==",
                    "2024.3.1"
                ]
            ]
        },
        {
            "name": "h11",
            "specs": [
                [
                    "==",
                    "0.14.0"
                ]
            ]
        },
        {
            "name": "httpcore",
            "specs": [
                [
                    "==",
                    "1.0.4"
                ]
            ]
        },
        {
            "name": "httpx",
            "specs": [
                [
                    "==",
                    "0.27.0"
                ]
            ]
        },
        {
            "name": "huggingface-hub",
            "specs": [
                [
                    "==",
                    "0.22.0"
                ]
            ]
        },
        {
            "name": "idna",
            "specs": [
                [
                    "==",
                    "3.6"
                ]
            ]
        },
        {
            "name": "importlib-metadata",
            "specs": [
                [
                    "==",
                    "7.1.0"
                ]
            ]
        },
        {
            "name": "jinja2",
            "specs": [
                [
                    "==",
                    "3.1.3"
                ]
            ]
        },
        {
            "name": "litellm",
            "specs": [
                [
                    "==",
                    "1.34.0"
                ]
            ]
        },
        {
            "name": "loguru",
            "specs": [
                [
                    "==",
                    "0.7.2"
                ]
            ]
        },
        {
            "name": "markupsafe",
            "specs": [
                [
                    "==",
                    "2.1.5"
                ]
            ]
        },
        {
            "name": "multidict",
            "specs": [
                [
                    "==",
                    "6.0.5"
                ]
            ]
        },
        {
            "name": "numexpr",
            "specs": [
                [
                    "==",
                    "2.8.6"
                ]
            ]
        },
        {
            "name": "numpy",
            "specs": [
                [
                    "==",
                    "1.24.4"
                ]
            ]
        },
        {
            "name": "openai",
            "specs": [
                [
                    "==",
                    "1.14.2"
                ]
            ]
        },
        {
            "name": "packaging",
            "specs": [
                [
                    "==",
                    "23.2"
                ]
            ]
        },
        {
            "name": "prompt-toolkit",
            "specs": [
                [
                    "==",
                    "3.0.36"
                ]
            ]
        },
        {
            "name": "pydantic-core",
            "specs": [
                [
                    "==",
                    "2.16.3"
                ]
            ]
        },
        {
            "name": "pydantic",
            "specs": [
                [
                    "==",
                    "2.6.4"
                ]
            ]
        },
        {
            "name": "python-dotenv",
            "specs": [
                [
                    "==",
                    "1.0.1"
                ]
            ]
        },
        {
            "name": "pyyaml",
            "specs": [
                [
                    "==",
                    "6.0.1"
                ]
            ]
        },
        {
            "name": "questionary",
            "specs": [
                [
                    "==",
                    "2.0.1"
                ]
            ]
        },
        {
            "name": "regex",
            "specs": [
                [
                    "==",
                    "2023.12.25"
                ]
            ]
        },
        {
            "name": "requests",
            "specs": [
                [
                    "==",
                    "2.31.0"
                ]
            ]
        },
        {
            "name": "sniffio",
            "specs": [
                [
                    "==",
                    "1.3.1"
                ]
            ]
        },
        {
            "name": "tiktoken",
            "specs": [
                [
                    "==",
                    "0.6.0"
                ]
            ]
        },
        {
            "name": "tokenizers",
            "specs": [
                [
                    "==",
                    "0.15.2"
                ]
            ]
        },
        {
            "name": "tqdm",
            "specs": [
                [
                    "==",
                    "4.66.2"
                ]
            ]
        },
        {
            "name": "typing-extensions",
            "specs": [
                [
                    "==",
                    "4.10.0"
                ]
            ]
        },
        {
            "name": "urllib3",
            "specs": [
                [
                    "==",
                    "2.2.1"
                ]
            ]
        },
        {
            "name": "wcwidth",
            "specs": [
                [
                    "==",
                    "0.2.13"
                ]
            ]
        },
        {
            "name": "win32-setctime",
            "specs": [
                [
                    "==",
                    "1.1.0"
                ]
            ]
        },
        {
            "name": "yarl",
            "specs": [
                [
                    "==",
                    "1.9.4"
                ]
            ]
        },
        {
            "name": "zipp",
            "specs": [
                [
                    "==",
                    "3.18.1"
                ]
            ]
        }
    ],
    "lcname": "promptulate"
}
        
Elapsed time: 0.24310s