Advanced hairstyle recommendation agent with rule-based scoring
Project description
Hair Recommendation Agent
A lightweight, rule-based agent for hairstyle and hair-color recommendations (no LLM required).
This package provides rule-based recommendations and compatibility analysis for hairstyles, based on face shape, hair type and simple style profiles. The agent accepts structured inputs (e.g. face_shape, hair_type) and can also accept free-form descriptions for style/color when appropriate.
Key features
- Hairstyle recommendations tailored to face shape and hair type.
- Style compatibility analysis for specific haircuts.
- Trending styles by season.
- Simple, testable API designed to integrate into UIs and orchestrators.
Installation
Developer editable install:
python -m pip install -e .[dev]
Install from PyPI (when published):
pip install hair-recommendation-agent
Install directly from the repository:
pip install git+https://github.com/msalsas/hair-recommendation-agent.git
Quick start
from hair_recommendation_agent import HairRecommendationAgent
from agent_core_framework import AgentTask
# Create the agent
agent = HairRecommendationAgent()
# Example: get hairstyle recommendations using structured fields
task = AgentTask(
type="get_hairstyle_recommendations",
payload={
"face_shape": "oval",
"hair_type": "wavy",
"personal_style": "bohemian",
"age_group": "adult",
"gender": "female",
"hair_length": "medium"
}
)
response = agent.process(task)
print(response.success, response.error)
print(response.data)
Supported task types (examples): get_hairstyle_recommendations, analyze_style_compatibility, get_trending_styles.
Testing
Run the test suite locally:
PYTHONPATH=src pytest -q
Publishing to TestPyPI (manual)
- Bump the version in
pyproject.toml(e.g.0.2.0). - Build distributions:
python -m build
- Upload to TestPyPI (create a TestPyPI API token first):
python -m twine upload --repository-url https://test.pypi.org/legacy/ dist/*
CI notes
You can add GitHub Actions workflows to run tests and publish packages. Make sure the runner has any test dependencies available.
Contributing
Contributions are welcome. Open an issue or a pull request. Add tests for new behavior and keep changes focused.
License
MIT — see the LICENSE file for details.
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 hair_recommendation_agent-0.1.1.tar.gz.
File metadata
- Download URL: hair_recommendation_agent-0.1.1.tar.gz
- Upload date:
- Size: 14.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
447a6c72c1308a640fe33d6a219675b35925c2c1751c71e6a11af9a4e0b499d0
|
|
| MD5 |
79934cb22c49b78c68f9c4d50e6fe873
|
|
| BLAKE2b-256 |
621c605c6de63295bed50c3982381a6f6e6186b254b48ecc3872cd54de943435
|
File details
Details for the file hair_recommendation_agent-0.1.1-py2.py3-none-any.whl.
File metadata
- Download URL: hair_recommendation_agent-0.1.1-py2.py3-none-any.whl
- Upload date:
- Size: 12.8 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d96601f3a08acf6ada0359b3bca2df8a2333da6a0c03fe6395d79edf29eb0796
|
|
| MD5 |
e2e8335e5c3eeb6f18b85ac7cd176fc5
|
|
| BLAKE2b-256 |
09054787fca2519f07121aa8702afaeed08360524f33951c4b024b35c2d7556c
|