Skip to main content

一个将自然语言需求转换为命令行命令的AI工具

Project description

AI-Bash: 智能命令行工具

一个基于大模型的命令行工具,可以将自然语言需求转换为对应平台的命令行命令。

功能介绍

  • 接收用户的自然语言描述
  • 调用大模型API将需求转换为命令行命令
  • 自动识别用户的操作系统和命令行环境
  • 根据当前平台生成最适合的命令
  • 支持自定义API密钥、主机地址和模型名称
  • 生成命令并在用户确认后执行

快速开始

安装:

uv pip install ai_bash

使用:

# 基本用法(生成命令并等待用户回车后执行)
ai_bash "查一下当前目录的文件路径"

# 只生成命令不执行
ai_bash "列出所有进程" --no-exec

# 查看帮助信息
ai_bash --help

配置

在用户主目录下创建.cmd_ai文件:

# 必需的API密钥
OPENAI_API_KEY=你的OpenAI API密钥

文档与贡献

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ai_bash-0.1.0.tar.gz (42.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ai_bash-0.1.0-py3-none-any.whl (7.5 kB view details)

Uploaded Python 3

File details

Details for the file ai_bash-0.1.0.tar.gz.

File metadata

  • Download URL: ai_bash-0.1.0.tar.gz
  • Upload date:
  • Size: 42.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for ai_bash-0.1.0.tar.gz
Algorithm Hash digest
SHA256 2f2f9d54f2b672519d12368b2dbd68e624cf503ce37e08966edcb2970e6a5c20
MD5 0e28bce4db68ea2c2c05f989397d097b
BLAKE2b-256 b15a04b6860f7b93e84981899af5d925a17a06191e1aaf46c00badd82f19140c

See more details on using hashes here.

Provenance

The following attestation bundles were made for ai_bash-0.1.0.tar.gz:

Publisher: python-publish.yml on weiwei2012holy/cmd_ai

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file ai_bash-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: ai_bash-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 7.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for ai_bash-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 406eeeb333cc53816066d7afe112e998300165b827a3879a102aac8cbfc396d4
MD5 ca756d25a9063938ce23cabfe1bcc8f9
BLAKE2b-256 8fd312123e450eb1962549b49286c467c2c247f3e584abebc5b1eac6c45f5412

See more details on using hashes here.

Provenance

The following attestation bundles were made for ai_bash-0.1.0-py3-none-any.whl:

Publisher: python-publish.yml on weiwei2012holy/cmd_ai

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page