This system takes a textual synopsis of a cryptographic scheme and extracts a structured summary that highlights its key components, such as the types of finite fields used, the encryption process, ke
Project description
cryptoschema-extractor
A Python package that extracts structured summaries of cryptographic schemes from textual descriptions.
Overview
This system takes a textual synopsis of a cryptographic scheme and extracts a structured summary that highlights its key components, such as the types of finite fields used, the encryption process, key generation, and the mathematical principles underlying the cryptosystem. It transforms unstructured textual references into a predictable, organized format suitable for inclusion in catalogs, research summaries, or educational material.
Installation
pip install cryptoschema_extractor
Usage
Basic Usage
from cryptoschema_extractor import cryptoschema_extractor
response = cryptoschema_extractor(user_input="Your text here")
print(response)
Using a Custom LLM
You can use any LLM compatible with LangChain by passing an instance of it to the cryptoschema_extractor function.
Example with OpenAI
from langchain_openai import ChatOpenAI
from cryptoschema_extractor import cryptoschema_extractor
llm = ChatOpenAI()
response = cryptoschema_extractor(user_input="Your text here", llm=llm)
print(response)
Example with Anthropic
from langchain_anthropic import ChatAnthropic
from cryptoschema_extractor import cryptoschema_extractor
llm = ChatAnthropic()
response = cryptoschema_extractor(user_input="Your text here", llm=llm)
print(response)
Example with Google
from langchain_google_genai import ChatGoogleGenerativeAI
from cryptoschema_extractor import cryptoschema_extractor
llm = ChatGoogleGenerativeAI()
response = cryptoschema_extractor(user_input="Your text here", llm=llm)
print(response)
Using a Custom API Key
If you want to use a custom API key for LLM7, you can pass it directly or set it as an environment variable.
Passing API Key Directly
from cryptoschema_extractor import cryptoschema_extractor
response = cryptoschema_extractor(user_input="Your text here", api_key="your_api_key")
print(response)
Setting API Key via Environment Variable
export LLM7_API_KEY="your_api_key"
from cryptoschema_extractor import cryptoschema_extractor
response = cryptoschema_extractor(user_input="Your text here")
print(response)
Parameters
user_input(str): The user input text to process.llm(Optional[BaseChatModel]): The LangChain LLM instance to use. If not provided, the defaultChatLLM7will be used.api_key(Optional[str]): The API key for LLM7. If not provided, the environment variableLLM7_API_KEYwill be used.
Default LLM
By default, this package uses ChatLLM7 from langchain_llm7.
Rate Limits
The default rate limits for LLM7 free tier are sufficient for most use cases of this package. If you want higher rate limits, you can pass your own API key via the environment variable LLM7_API_KEY or directly to the cryptoschema_extractor function. You can get a free API key by registering at LLM7.
Issues
If you encounter any issues, please report them on the GitHub issues page.
Author
- Eugene Evstafev
- Email: hi@eugene.plus
- GitHub: chigwell
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file cryptoschema_extractor-2025.12.21112205.tar.gz.
File metadata
- Download URL: cryptoschema_extractor-2025.12.21112205.tar.gz
- Upload date:
- Size: 4.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f12d4595e3135c1016d1131069eb2c3ffc2cd62e7f9dfcac818d8b4654431a0d
|
|
| MD5 |
19206fa8d81e5e9944689d65af7d2d90
|
|
| BLAKE2b-256 |
a2488669026420bfd5bfa1b69291c4927434dbbd14b157d674da21efd90ee360
|
File details
Details for the file cryptoschema_extractor-2025.12.21112205-py3-none-any.whl.
File metadata
- Download URL: cryptoschema_extractor-2025.12.21112205-py3-none-any.whl
- Upload date:
- Size: 4.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
737313c314c02380e2e2b9934257afec1bd8d859e3044a2d9d6c2599b49b64f7
|
|
| MD5 |
a02e4ec179aa326a11e6e09ef1112d5f
|
|
| BLAKE2b-256 |
1d6f2a4d6fa4e092f48577515a9573078d0a4f7ce5f45ff3a7f290f4860020d2
|