hermes-currenttime-hint/pyproject.toml
Shihfu Juan 8625ba115a
feat: initial hermes-currenttime-hint plugin
Appends an ISO 8601 current-time tag to the user message tail via the
pre_llm_call hook. Two independent triggers, whichever fires first:

- USER_MESSAGE_INTERVAL (default 5): every Nth user message
- TIME_INTERVAL_SECONDS (default 1800): wall-clock interval

First injection for a session always fires on the very first user
message. State is held in memory only (lazy TTL + 1024-session LRU
cap). Per-session state is dropped on on_session_end.

Time format: ISO 8601 with UTC offset, second precision. Honours $TZ
via POSIX time.tzset() if set; defaults to host local timezone.

Plugin is opt-in via 'hermes plugins enable hermes-currenttime-hint'.
No per-plugin configuration. Plugin.yaml hooks and register() wiring
are validated by tests/test_registration.py.
2026-07-10 19:08:35 +08:00

34 lines
No EOL
732 B
TOML

[project]
name = "hermes-currenttime-hint"
version = "0.1.0"
description = "Appends current-time hints to user messages via pre_llm_call"
requires-python = ">=3.12"
[tool.ruff]
line-length = 100
[tool.ruff.lint]
select = ["I", "E", "F", "W", "N", "UP", "B", "SIM", "PL", "RUF"]
ignore = [
"N999", # Plugin dir names use hyphens
"PLR2004", # Magic-value comparison fine in tests
]
exclude = [".venv", "dist", "__pycache__"]
[tool.pytest.ini_options]
testpaths = ["tests"]
pythonpath = ["."]
[tool.bandit]
targets = ["__init__.py", "tests/"]
skips = ["B101"] # allow assert
[dependency-groups]
dev = [
"ruff>=0.6.0",
"pytest>=8.0",
"ty>=0.0.49",
"bandit>=1.7",
"vulture>=2.7",
"pyyaml>=6.0",
]