bizact-insights is a Python package designed to process text inputs related to corporate actions, such as trademark filings or product launches, and extract structured insights. It identifies key entities, actions, and contextual information from news snippets or official statements, enabling users to quickly grasp business-related developments.
Install the package via pip:
pip install bizact_insightsfrom bizact_insights import bizact_insights
# Example usage with default LLM7
results = bizact_insights(
user_input="Apple announced the launch of a new product line in Europe.",
)
print(results)user_input(str): The input text to analyze.llm(Optional[BaseChatModel]): An instance of a language model (e.g., from langchain). If not provided, the default ChatLLM7 will be used.api_key(Optional[str]): API key for LLM7. If not provided, it can be set via the environment variableLLM7_API_KEY.
This package relies on the ChatLLM7 class from langchain_llm7, which offers a straightforward interface to the LLM7 API. It can also accept custom language model instances, allowing integration with other providers such as OpenAI, Anthropic, or Google Generative AI.
from langchain_openai import ChatOpenAI
from bizact_insights import bizact_insights
llm = ChatOpenAI()
response = bizact_insights(user_input="Tesla reported record deliveries.", llm=llm)
print(response)from langchain_anthropic import ChatAnthropic
from bizact_insights import bizact_insights
llm = ChatAnthropic()
response = bizact_insights(user_input="Microsoft announced a new cloud service.", llm=llm)
print(response)from langchain_google_genai import ChatGoogleGenerativeAI
from bizact_insights import bizact_insights
llm = ChatGoogleGenerativeAI()
response = bizact_insights(user_input="Google is expanding its workspace features.", llm=llm)
print(response)The default usage via LLM7's free tier offers sufficient rate limits for most purposes. For higher throughput, you can obtain a free API key by registering at https://token.llm7.io/ and set it via the LLM7_API_KEY environment variable or pass it directly:
results = bizact_insights(user_input="Sample text", api_key="your_api_key_here")If you encounter issues or have questions, please open an issue on the GitHub repository.
Eugene Evstafev
Email: hi@euegne.plus
GitHub: chigwell