npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

content-qa

v0.0.1

Published

A command line utility to quickly send the contents of files, directories, URLs, and glob patterns to an OpenAI agent which will answer any questions you have about them.

Downloads

2

Readme

Content QA CLI Tool

Content QA is a command-line interface (CLI) tool designed to gather content from various sources such as files, directories, URLs, and glob patterns. It builds a comprehensive system message containing a file tree and contents which can then be used to interact with a chatbot agent like GPT-4 for content quality analysis or other tasks.

Features

  • Gathers content from files, directories, and URLs.
  • Supports glob patterns to select multiple files.
  • Extracts content from various file types such as plain text and PDF.
  • Processes video URLs to extract subtitles as text.
  • Communicates with a chatbot agent to perform content-related tasks.
  • Utilizes OpenAI's GPT-4 (preview) for conversational intelligence.

Installation

Before installation, ensure that you have Node.js (version 18 or above) installed on your system.

To quickly get started with the CLI, you can install it globally:

npm i -g content-qa

Configuration

Content QA uses Open AI and requires you to provide your own API key. You can provide it via the CLI using this command:

cqa set config.openai_key <your-openai-api-key>

Alternatively, ensure OPENAI_API_KEY is in your environment or create a .env file in the project root with the following variable:

OPENAI_API_KEY=<your-openai-api-key>

Usage

To use the Content QA CLI tool, run the following command in your terminal with the desired options:

content-qa [options]

cqa [options]

You can also just pass in a file path or URL with no flags:

cqa https://example.com

Warning: Be mindful of what you are putting in to the system, as the content will be sent to OpenAI.

Options

  • -i, --input [path...]: Specify a URL, file, or directory to include as input.
  • -e, --exclude [path...]: Exclude a particular file or directory from being processed.

Examples

Gathering content from a specific URL:

content-qa --input https://example.com/article

Including files and directories using glob patterns:

content-qa --input "content/**/*.txt"

Interacting with the Chatbot Agent

Once the inputs are gathered, the system message is built, which is then used to establish a connection with the chatbot agent. You can interact with the agent through the CLI and use it to perform quality analysis or receive information based on the provided content.

Development

The tool can be run during development through npm:

npm run start -i your_input

Run the tool in development mode by executing:

npm run dev

License

Content QA is released under the MIT License. See the LICENSE file for details.

Contact

For any queries or support, please open an issue on the project's GitHub repository.