yaicli 0.0.2__tar.gz → 0.0.3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,5 +1,5 @@
1
1
  [bumpversion]
2
- current_version = 0.0.2
2
+ current_version = 0.0.3
3
3
  commit = True
4
4
  tag = True
5
5
 
@@ -0,0 +1,33 @@
1
+
2
+ ---
3
+ ## [0.0.3](https://github.com/belingud/yaicli/compare/v0.0.2..v0.0.3) - 2025-04-02
4
+
5
+ ### 🚜 Refactor
6
+
7
+ - **(changelog)** switch from git log to git cliff for changelog generation - ([242a51d](https://github.com/belingud/yaicli/commit/242a51d93a25675041a7fe19c4a0db1c7c12a663)) - Belingud
8
+ - update CLI assistant description and error handling - ([1a8bcdc](https://github.com/belingud/yaicli/commit/1a8bcdc86c72a75259d266291bc9e5350fc81f61)) - Belingud
9
+ - fix spacing in clean target and simplify build target - ([2a1050e](https://github.com/belingud/yaicli/commit/2a1050e7a9eea8753c164553b13796e5510b7965)) - Belingud
10
+
11
+
12
+ ---
13
+ ## [0.0.2] - 2025-04-02
14
+
15
+ ### ⛰️ Features
16
+
17
+ - enhance OS detection and LLM API request handling - ([8c00de0](https://github.com/belingud/yaicli/commit/8c00de099e1c75fedcdd33e9d7e0443818538059)) - Belingud
18
+ - add new dependencies and configurable API paths - ([3be3f67](https://github.com/belingud/yaicli/commit/3be3f67b3bd9645a9a8c9909be0e5542612c1c71)) - Belingud
19
+
20
+ ### 🚜 Refactor
21
+
22
+ - **(config)** migrate config from JSON to INI format and enhance error handling - ([f556872](https://github.com/belingud/yaicli/commit/f556872fdb521adf8e20da6498fdaac26998a5b7)) - Belingud
23
+ - update config path to reflect project name change - ([e6bf761](https://github.com/belingud/yaicli/commit/e6bf761aa0fae20b643848c586c6dc55d6f324fb)) - Belingud
24
+ - rename project from llmcli to yaicli and update related files - ([cdb5a97](https://github.com/belingud/yaicli/commit/cdb5a97d06c9f042c1c8731c8f11a4a7284783f0)) - Belingud
25
+ - rename project from shellai to llmcli and update related files - ([db4ecb8](https://github.com/belingud/yaicli/commit/db4ecb85236b72fd7536c99b21d210037c09889e)) - Belingud
26
+ - reorganize imports and improve code readability - ([0f52c05](https://github.com/belingud/yaicli/commit/0f52c05918d177d4623ff2f07aff2fc2e3aa9e91)) - Belingud
27
+ - migrate llmcli to class-based ShellAI implementation - ([2509cba](https://github.com/belingud/yaicli/commit/2509cba5cad7c8626f794d88d971fff7eea9a404)) - Belingud
28
+
29
+ ### Build
30
+
31
+ - add bump2version for version management - ([de287f1](https://github.com/belingud/yaicli/commit/de287f1262eae64ae5fd0cb634dea93762a17282)) - Belingud
32
+
33
+
@@ -17,8 +17,9 @@ test:
17
17
  @pytest tests/
18
18
 
19
19
  # Build package with hatch (runs clean first)
20
- build: clean
20
+ build:
21
21
  @echo "Building package..."
22
+ @rm -rf dist/
22
23
  @uv build
23
24
 
24
25
  # Install package in editable mode
@@ -29,4 +30,4 @@ install:
29
30
  # Generate changelog from git log
30
31
  changelog:
31
32
  @echo "Generating changelog..."
32
- @git log --oneline --decorate --graph > CHANGELOG.md
33
+ @git cliff -l --prepend CHANGELOG.md
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: yaicli
3
- Version: 0.0.2
3
+ Version: 0.0.3
4
4
  Summary: A simple CLI tool to interact with LLM
5
5
  License-File: LICENSE
6
6
  Requires-Python: >=3.8
@@ -0,0 +1,90 @@
1
+ # git-cliff ~ configuration file
2
+ # https://git-cliff.org/docs/configuration
3
+
4
+ [changelog]
5
+ # template for the changelog header
6
+ header = """"""
7
+ # template for the changelog body
8
+ # https://keats.github.io/tera/docs/#introduction
9
+ body = """
10
+ ---
11
+ {% if version %}\
12
+ {% if previous.version %}\
13
+ ## [{{ version | trim_start_matches(pat="v") }}]($REPO/compare/{{ previous.version }}..{{ version }}) - {{ timestamp | date(format="%Y-%m-%d") }}
14
+ {% else %}\
15
+ ## [{{ version | trim_start_matches(pat="v") }}] - {{ timestamp | date(format="%Y-%m-%d") }}
16
+ {% endif %}\
17
+ {% else %}\
18
+ ## [unreleased]
19
+ {% endif %}\
20
+ {% for group, commits in commits | group_by(attribute="group") %}
21
+ ### {{ group | striptags | trim | upper_first }}
22
+ {% for commit in commits
23
+ | filter(attribute="scope")
24
+ | sort(attribute="scope") %}
25
+ - **({{commit.scope}})**{% if commit.breaking %} [**breaking**]{% endif %} \
26
+ {{ commit.message }} - ([{{ commit.id | truncate(length=7, end="") }}]($REPO/commit/{{ commit.id }})) - {{ commit.author.name }}
27
+ {%- endfor -%}
28
+ {% raw %}\n{% endraw %}\
29
+ {%- for commit in commits %}
30
+ {%- if commit.scope -%}
31
+ {% else -%}
32
+ - {% if commit.breaking %} [**breaking**]{% endif %}\
33
+ {{ commit.message }} - ([{{ commit.id | truncate(length=7, end="") }}]($REPO/commit/{{ commit.id }})) - {{ commit.author.name }}
34
+ {% endif -%}
35
+ {% endfor -%}
36
+ {% endfor %}\n
37
+ """
38
+ # template for the changelog footer
39
+ footer = """"""
40
+ # remove the leading and trailing whitespace from the templates
41
+ trim = true
42
+ # postprocessors
43
+ postprocessors = [
44
+ { pattern = '\$REPO', replace = "https://github.com/belingud/yaicli" }, # replace repository URL
45
+ ]
46
+
47
+ [git]
48
+ # parse the commits based on https://www.conventionalcommits.org
49
+ conventional_commits = true
50
+ # filter out the commits that are not conventional
51
+ filter_unconventional = true
52
+ # process each line of a commit as an individual commit
53
+ split_commits = false
54
+ # regex for preprocessing the commit messages
55
+ commit_preprocessors = [
56
+ # { pattern = '\((\w+\s)?#([0-9]+)\)', replace = "([#${2}](https://github.com/orhun/git-cliff/issues/${2}))"}, # replace issue numbers
57
+ ]
58
+ # regex for parsing and grouping commits
59
+ commit_parsers = [
60
+ { message = "^feat", group = "<!-- 0 -->⛰️ Features" },
61
+ { message = "^fix", group = "<!-- 1 -->🐛 Bug Fixes" },
62
+ { message = "^doc", group = "<!-- 3 -->📚 Documentation" },
63
+ { message = "^perf", group = "<!-- 4 -->⚡ Performance" },
64
+ { message = "^refactor\\(clippy\\)", skip = true },
65
+ { message = "^refactor", group = "<!-- 2 -->🚜 Refactor" },
66
+ { message = "^style", group = "<!-- 5 -->🎨 Styling" },
67
+ { message = "^test", group = "<!-- 6 -->🧪 Testing" },
68
+ { message = "^chore\\(release\\): prepare for", skip = true },
69
+ { message = "^chore\\(deps.*\\)", skip = true },
70
+ { message = "^chore\\(pr\\)", skip = true },
71
+ { message = "^chore\\(pull\\)", skip = true },
72
+ { message = "^chore\\(npm\\).*yarn\\.lock", skip = true },
73
+ { message = "^chore|^ci", group = "<!-- 7 -->⚙️ Miscellaneous Tasks" },
74
+ { body = ".*security", group = "<!-- 8 -->🛡️ Security" },
75
+ { message = "^revert", group = "<!-- 9 -->◀️ Revert" },
76
+ ]
77
+ # protect breaking changes from being skipped due to matching a skipping commit_parser
78
+ protect_breaking_commits = false
79
+ # filter out the commits that are not matched by commit parsers
80
+ filter_commits = false
81
+ # regex for matching git tags
82
+ tag_pattern = "v[0-9].*"
83
+ # regex for skipping tags
84
+ skip_tags = "beta|alpha"
85
+ # regex for ignoring tags
86
+ ignore_tags = "rc|beta"
87
+ # sort the tags topologically
88
+ topo_order = false
89
+ # sort the commits inside sections by oldest/newest order
90
+ sort_commits = "newest"
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "yaicli"
3
- version = "0.0.2"
3
+ version = "0.0.3"
4
4
  description = "A simple CLI tool to interact with LLM"
5
5
  readme = "README.md"
6
6
  requires-python = ">=3.8"
@@ -416,7 +416,7 @@ wheels = [
416
416
 
417
417
  [[package]]
418
418
  name = "yaicli"
419
- version = "0.0.1"
419
+ version = "0.0.3"
420
420
  source = { editable = "." }
421
421
  dependencies = [
422
422
  { name = "distro" },
@@ -126,9 +126,8 @@ Rules:
126
126
  _os = self.detect_os()
127
127
  _shell = self.detect_shell()
128
128
  return (
129
- "You are a system and code assistant, "
130
- f"focusing on {_os} and {_shell}. "
131
- "Assist with system management, script writing, and coding tasks. "
129
+ "You are yaili, a system management and programing assistant, "
130
+ f"You are managing {_os} operating system with {_shell} shell. "
132
131
  "Your responses should be concise and use Markdown format, "
133
132
  "unless the user explicitly requests more details."
134
133
  )
@@ -235,6 +234,8 @@ Rules:
235
234
  response = self._call_api(url, headers, data)
236
235
  except requests.exceptions.RequestException as e:
237
236
  self.console.print(f"[red]Error calling API: {e}[/red]")
237
+ if self.verbose and e.response:
238
+ self.console.print(f"{e.response.text}")
238
239
  raise typer.Exit(code=1) from None
239
240
  if not response:
240
241
  raise typer.Exit(code=1)
@@ -438,7 +439,7 @@ def main(
438
439
  ] = False,
439
440
  ):
440
441
  """LLM CLI Tool"""
441
- cli = ShellAI()
442
+ cli = ShellAI(verbose=verbose)
442
443
  cli.run(chat=chat, shell=shell, prompt=prompt)
443
444
 
444
445
 
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes