diff --git a/.github/dependabot.yml b/.github/dependabot.yml deleted file mode 100644 index 575048f..0000000 --- a/.github/dependabot.yml +++ /dev/null @@ -1,12 +0,0 @@ -# To get started with Dependabot version updates, you'll need to specify which -# package ecosystems to update and where the package manifests are located. -# Please see the documentation for all configuration options: -# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates - -version: 2 -updates: - - package-ecosystem: "nuget" - directory: "/src" - schedule: - interval: "daily" - open-pull-requests-limit: 25 diff --git a/.github/workflows/continuous.yml b/.github/workflows/continuous.yml index e11eadb..03d0fab 100644 --- a/.github/workflows/continuous.yml +++ b/.github/workflows/continuous.yml @@ -16,24 +16,33 @@ name: continuous -on: [push] +on: + push: + branches: [ "main" ] + pull_request: + branches: [ "main" ] + +concurrency: + group: ci-${{ github.ref }} + cancel-in-progress: true jobs: ubuntu-latest: name: ubuntu-latest runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v6 with: fetch-depth: 0 - name: Setup dotnet - uses: actions/setup-dotnet@v4 + uses: actions/setup-dotnet@v5 with: dotnet-version: | 8.0.x 9.0.x + 10.0.x - name: 'Cache: .nuke/temp, ~/.nuget/packages' - uses: actions/cache@v4 + uses: actions/cache@v5 with: path: | .nuke/temp diff --git a/README.md b/README.md index 139ffa7..378b66a 100644 --- a/README.md +++ b/README.md @@ -1,49 +1,109 @@ -# SalesPitch [![Sparkline](https://stars.medv.io/Atypical-Consulting/SalesPitch.svg)](https://stars.medv.io/Atypical-Consulting/SalesPitch) +# SalesPitch -SalesPitch is a sales pitch generation application using OpenAI GPT-4. Create impactful sales pitches for your products in just a few simple steps. +> **Generate tailored, professional sales pitches in seconds using AI — stop choosing between generic copy and hours of personalization.** + + +[![Atypical-Consulting - SalesPitch](https://img.shields.io/static/v1?label=Atypical-Consulting&message=SalesPitch&color=blue&logo=github)](https://github.com/Atypical-Consulting/SalesPitch) +[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE) +[![.NET 9](https://img.shields.io/badge/.NET-9.0-purple?logo=dotnet)](https://dotnet.microsoft.com/) +[![stars - SalesPitch](https://img.shields.io/github/stars/Atypical-Consulting/SalesPitch?style=social)](https://github.com/Atypical-Consulting/SalesPitch) +[![forks - SalesPitch](https://img.shields.io/github/forks/Atypical-Consulting/SalesPitch?style=social)](https://github.com/Atypical-Consulting/SalesPitch) + + +[![GitHub tag](https://img.shields.io/github/tag/Atypical-Consulting/SalesPitch?include_prereleases=&sort=semver&color=blue)](https://github.com/Atypical-Consulting/SalesPitch/releases/) +[![issues - SalesPitch](https://img.shields.io/github/issues/Atypical-Consulting/SalesPitch)](https://github.com/Atypical-Consulting/SalesPitch/issues) +[![GitHub pull requests](https://img.shields.io/github/issues-pr/Atypical-Consulting/SalesPitch)](https://github.com/Atypical-Consulting/SalesPitch/pulls) +[![GitHub last commit](https://img.shields.io/github/last-commit/Atypical-Consulting/SalesPitch)](https://github.com/Atypical-Consulting/SalesPitch/commits/main) + + +[![Build](https://github.com/Atypical-Consulting/SalesPitch/actions/workflows/continuous.yml/badge.svg)](https://github.com/Atypical-Consulting/SalesPitch/actions/workflows/continuous.yml) + +--- ![SalesPitch](./assets/salespitch.png) -## Features +## Table of Contents + +- [The Problem](#the-problem) +- [The Solution](#the-solution) +- [Features](#features) +- [Tech Stack](#tech-stack) +- [Getting Started](#getting-started) +- [Usage](#usage) +- [Architecture](#architecture) +- [Project Structure](#project-structure) +- [Roadmap](#roadmap) +- [Stats](#stats) +- [Contributing](#contributing) +- [License](#license) +- [Acknowledgments](#acknowledgments) -* Interacts with OpenAI GPT-4o to generate sales pitches -* Supports multiple languages (French, English, German, and Spanish) -* Includes various sales pitch frameworks - * AIDA (Attention, Interest, Desire, Action) - * PAS (Problem-Agitate-Solve) - * USP (Unique Selling Proposition) - * Features-Benefits - * Storytelling - * WIIFM (What’s In It For Me) - * Youtility - * FAB (Features, Advantages, Benefits) - * HHE (Headline, Hook, Empathy) - * SUSPENSE (Surprise, Uniqueness, Specifics, Promise, Excitement, Newness, Story) -* User-friendly interface with Spectre.Console -* Ability to use demo data +## The Problem -## Installation +Writing compelling, tailored sales pitches for every prospect is time-consuming. Sales teams either write generic pitches that fail to resonate, or spend hours personalizing each one. Existing tools lack support for proven sales frameworks and multi-language output, forcing teams to manually adapt their messaging for different audiences and markets. -Ensure that you have .NET 9.0 or a later version installed on your machine. +## The Solution -Clone this repository and navigate to the source folder: +**SalesPitch** uses OpenAI GPT-4 to generate tailored, professional sales pitches from minimal input via an interactive CLI. Choose from 10 proven sales frameworks, pick your target language, describe your product, and get a polished pitch in seconds. ```sh -git clone https://github.com/user/SalesPitch.git -cd SalesPitch +dotnet run --configuration Release --project src/SalesPitch + +# The interactive CLI will guide you through: +# 1. Select a language (French, English, German, Spanish) +# 2. Choose a sales framework (AIDA, PAS, USP, etc.) +# 3. Describe your product +# 4. Receive a tailored sales pitch powered by GPT-4 ``` -Install the dependencies and build the project: +## Features -```sh +- [x] AI-powered pitch generation using OpenAI GPT-4o +- [x] 10 proven sales pitch frameworks (AIDA, PAS, USP, Features-Benefits, Storytelling, WIIFM, Youtility, FAB, HHE, SUSPENSE) +- [x] Multi-language support (French, English, German, Spanish) +- [x] Interactive CLI powered by Spectre.Console +- [x] Demo data mode for quick evaluation +- [x] User secrets support for secure API key storage + +## Tech Stack + +| Layer | Technology | +|-------|-----------| +| Runtime | .NET 9.0 | +| AI | OpenAI GPT-4 via [Betalgo.Ranul.OpenAI](https://github.com/betalgo/openai) 9.x | +| CLI | [Spectre.Console](https://spectreconsole.net/) 0.49 | +| DI | [Scrutor](https://github.com/khellang/Scrutor) 5.x | +| Build | [Nuke](https://nuke.build/) | + +## Getting Started + +### Prerequisites + +- [.NET 9.0 SDK](https://dotnet.microsoft.com/download/dotnet/9.0) or later +- An [OpenAI API key](https://platform.openai.com/signup/) + +### Installation + +**From Source** + +```bash +git clone https://github.com/Atypical-Consulting/SalesPitch.git +cd SalesPitch dotnet restore dotnet build --configuration Release ``` -## Configuration +### Configuration + +Set your OpenAI API key using .NET user secrets (recommended): -1. Obtain an API key from OpenAI ([https://beta.openai.com/signup/](https://beta.openai.com/signup/)) -2. Create an `appsettings.json` file at the root of the project with the API key: +```bash +cd src/SalesPitch +dotnet user-secrets set "OpenAIServiceOptions:ApiKey" "" +dotnet user-secrets set "OpenAIServiceOptions:Organization" "" +``` + +Or create an `appsettings.json` file in the project root: ```json { @@ -56,26 +116,117 @@ dotnet build --configuration Release ## Usage -Run the application using the following command at the root of the project: +Run the application from the repository root: ```sh dotnet run --configuration Release --project src/SalesPitch ``` -The application will guide you through several steps to generate a sales pitch for your product. You can also use the demo data to see how the application works. +The interactive CLI will guide you through several steps to generate a sales pitch for your product. You can also use the demo data to see how the application works. + +## Architecture + +``` +┌─────────────────────────────────────────────────┐ +│ CLI Input │ +│ (Language, Framework, Product) │ +└──────────────────────┬──────────────────────────┘ + │ + ▼ +┌─────────────────────────────────────────────────┐ +│ Spectre.Console CLI │ +│ (Interactive prompts, rich formatting) │ +└──────────────────────┬──────────────────────────┘ + │ + ▼ +┌─────────────────────────────────────────────────┐ +│ Language Service Layer │ +│ (FR / EN / DE / ES prompt localization) │ +└──────────────────────┬──────────────────────────┘ + │ + ▼ +┌─────────────────────────────────────────────────┐ +│ OpenAI GPT-4 API │ +│ (Betalgo.Ranul.OpenAI SDK) │ +└──────────────────────┬──────────────────────────┘ + │ + ▼ +┌─────────────────────────────────────────────────┐ +│ Formatted Output │ +│ (Sales pitch in chosen language) │ +└─────────────────────────────────────────────────┘ +``` + +### Project Structure + +``` +SalesPitch/ +├── src/ +│ └── SalesPitch/ +│ ├── Commands/ # CLI command definitions and settings +│ ├── Extensions/ # Response extension methods +│ ├── Infrastructure/ # DI type resolver and registrar +│ ├── Services/ +│ │ └── Language/ # Language-specific prompt services +│ ├── TypeConverters/ # Custom type converters +│ └── Program.cs # Application entry point +├── build/ # Nuke build automation +├── assets/ # Screenshots and images +├── SalesPitch.sln # Solution file +└── README.md +``` + +## Roadmap -## Contribution +- [ ] Add more languages (Italian, Portuguese, Japanese, Chinese) +- [ ] Template customization — let users define custom pitch structures +- [ ] Batch generation — generate pitches for multiple products at once +- [ ] Export to PDF/Markdown/HTML +- [ ] Tone control — formal, casual, persuasive, technical +- [ ] Cost estimation — show token usage and API cost per generation -If you wish to contribute to this project, please submit a pull request or open an issue in the GitHub repository. +> Want to contribute? Pick any roadmap item and open a PR! + +## Stats + +![Alt](https://repobeats.axiom.co/api/embed/9e8cea0532101e0c02a5034825d6be9f1b40f732.svg "Repobeats analytics image") + +## Contributing + +Contributions are welcome! Here's how to get started: + +1. Fork the repository +2. Create your feature branch (`git checkout -b feature/amazing-feature`) +3. Commit using [conventional commits](https://www.conventionalcommits.org/) (`git commit -m 'feat: add amazing feature'`) +4. Push to the branch (`git push origin feature/amazing-feature`) +5. Open a Pull Request + +### Conventional Commits + +This project follows the [Conventional Commits](https://www.conventionalcommits.org/) specification: + +| Prefix | Purpose | +|--------|---------| +| `feat:` | A new feature | +| `fix:` | A bug fix | +| `docs:` | Documentation changes | +| `refactor:` | Code refactoring (no feature or fix) | +| `test:` | Adding or updating tests | +| `chore:` | Maintenance tasks | ## License -This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for more details. +[MIT](LICENSE) © 2023 [Atypical Consulting](https://atypical.garry-ai.cloud) ## Acknowledgments -This application was inspired by the following article: [Write A Great Chat GPT Sales Pitch in 5 Steps](https://txtly.ai/write-a-chat-gpt-sales-pitch/) +- Inspired by [Write A Great Chat GPT Sales Pitch in 5 Steps](https://txtly.ai/write-a-chat-gpt-sales-pitch/) +- [OpenAI](https://openai.com/) — GPT-4 language model +- [Spectre.Console](https://spectreconsole.net/) — Beautiful CLI framework for .NET +- [Betalgo.OpenAI](https://github.com/betalgo/openai) — .NET SDK for OpenAI + +--- + +Built with care by [Atypical Consulting](https://atypical.garry-ai.cloud) — opinionated, production-grade open source. -* [OpenAI](https://openai.com/) -* [Spectre.Console](https://spectreconsole.net/) -* [Betalgo.OpenAI](https://github.com/betalgo/openai) \ No newline at end of file +[![Contributors](https://contrib.rocks/image?repo=Atypical-Consulting/SalesPitch)](https://github.com/Atypical-Consulting/SalesPitch/graphs/contributors) diff --git a/build/Build.cs b/build/Build.cs index 500df9f..6ad802b 100644 --- a/build/Build.cs +++ b/build/Build.cs @@ -12,8 +12,6 @@ using Nuke.Common.Utilities.Collections; using Serilog; using static Nuke.Common.EnvironmentInfo; -using static Nuke.Common.IO.FileSystemTasks; -using static Nuke.Common.IO.PathConstruction; using static Nuke.Common.Tools.DotNet.DotNetTasks; // ReSharper disable AllUnderscoreLocalParameterName diff --git a/build/_build.csproj b/build/_build.csproj index 23d6bad..99fb31c 100644 --- a/build/_build.csproj +++ b/build/_build.csproj @@ -2,7 +2,7 @@ Exe - net9.0 + net10.0 CS0649;CS0169;CA1050;CA1822;CA2211;IDE1006 .. @@ -12,11 +12,7 @@ - - - - - + diff --git a/global.json b/global.json new file mode 100644 index 0000000..ed07ad8 --- /dev/null +++ b/global.json @@ -0,0 +1,6 @@ +{ + "sdk": { + "version": "10.0.103", + "rollForward": "latestFeature" + } +} diff --git a/qodana.yaml b/qodana.yaml deleted file mode 100644 index 99a40de..0000000 --- a/qodana.yaml +++ /dev/null @@ -1,29 +0,0 @@ -#-------------------------------------------------------------------------------# -# Qodana analysis is configured by qodana.yaml file # -# https://www.jetbrains.com/help/qodana/qodana-yaml.html # -#-------------------------------------------------------------------------------# -version: "1.0" - -#Specify inspection profile for code analysis -profile: - name: qodana.starter - -#Enable inspections -#include: -# - name: - -#Disable inspections -#exclude: -# - name: -# paths: -# - - -#Execute shell command before Qodana execution (Applied in CI/CD pipeline) -#bootstrap: sh ./prepare-qodana.sh - -#Install IDE plugins before Qodana execution (Applied in CI/CD pipeline) -#plugins: -# - id: #(plugin id can be found at https://plugins.jetbrains.com) - -#Specify Qodana linter for analysis (Applied in CI/CD pipeline) -linter: jetbrains/qodana-dotnet:latest diff --git a/renovate.json b/renovate.json new file mode 100644 index 0000000..d11bbe8 --- /dev/null +++ b/renovate.json @@ -0,0 +1,51 @@ +{ + "$schema": "https://docs.renovatebot.com/renovate-schema.json", + "extends": [ + "config:recommended" + ], + "baseBranchPatterns": [ + "dev" + ], + "schedule": [ + "before 9am on Saturday" + ], + "timezone": "Europe/Brussels", + "labels": [ + "dependencies", + "renovate" + ], + "packageRules": [ + { + "description": "Automerge minor and patch updates", + "matchUpdateTypes": [ + "minor", + "patch" + ], + "automerge": true, + "automergeType": "pr" + }, + { + "description": "Group all NuGet minor/patch updates together", + "matchManagers": [ + "nuget" + ], + "matchUpdateTypes": [ + "minor", + "patch" + ], + "groupName": "NuGet minor/patch updates" + }, + { + "description": "Group all NuGet major updates together", + "matchManagers": [ + "nuget" + ], + "matchUpdateTypes": [ + "major" + ], + "groupName": "NuGet major updates", + "dependencyDashboardApproval": true + } + ], + "platformAutomerge": true +} \ No newline at end of file diff --git a/src/SalesPitch/Commands/SalesPitchCommand.cs b/src/SalesPitch/Commands/SalesPitchCommand.cs index bf9498f..ded86cb 100644 --- a/src/SalesPitch/Commands/SalesPitchCommand.cs +++ b/src/SalesPitch/Commands/SalesPitchCommand.cs @@ -42,7 +42,8 @@ public SalesPitchCommand( /// The exit code public override async Task ExecuteAsync( CommandContext context, - SalesPitchSettings settings) + SalesPitchSettings settings, + CancellationToken cancellationToken) { // Display a header and a rule AnsiConsole.Write( diff --git a/src/SalesPitch/SalesPitch.csproj b/src/SalesPitch/SalesPitch.csproj index 5dcadbe..48da869 100644 --- a/src/SalesPitch/SalesPitch.csproj +++ b/src/SalesPitch/SalesPitch.csproj @@ -2,24 +2,24 @@ Exe - net9.0 + net10.0 enable enable 458c1c01-d3e1-4d45-9846-e8beb07f93ce - - - - - - + + + + + + all runtime; build; native; contentfiles; analyzers; buildtransitive - +