{"id":26549963,"url":"https://github.com/murikisaisrinivas/negotiatewithai","last_synced_at":"2026-04-02T18:52:24.753Z","repository":{"id":283607199,"uuid":"952321301","full_name":"MurikiSaiSrinivas/negotiatewithai","owner":"MurikiSaiSrinivas","description":"The AI Negotiation Game is an interactive, text-based negotiation game where players must persuade an AI-controlled villain to agree to a deal. The game is built using Google Gemini AI for dynamic conversations and Reddit's Devvit API for integration with Reddit's interactive posts.","archived":false,"fork":false,"pushed_at":"2025-03-21T05:10:45.000Z","size":357,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-21T06:20:56.452Z","etag":null,"topics":["css","devvit","game-development","gemini-api","html-css-javascript","interactive-post","javascript","negotiation","reddit"],"latest_commit_sha":null,"homepage":"https://www.reddit.com/r/negotiatewithai/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/MurikiSaiSrinivas.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-03-21T05:03:01.000Z","updated_at":"2025-03-21T05:12:23.000Z","dependencies_parsed_at":"2025-03-21T06:21:06.960Z","dependency_job_id":null,"html_url":"https://github.com/MurikiSaiSrinivas/negotiatewithai","commit_stats":null,"previous_names":["murikisaisrinivas/negotiatewithai"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MurikiSaiSrinivas%2Fnegotiatewithai","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MurikiSaiSrinivas%2Fnegotiatewithai/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MurikiSaiSrinivas%2Fnegotiatewithai/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MurikiSaiSrinivas%2Fnegotiatewithai/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/MurikiSaiSrinivas","download_url":"https://codeload.github.com/MurikiSaiSrinivas/negotiatewithai/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244920643,"owners_count":20532069,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["css","devvit","game-development","gemini-api","html-css-javascript","interactive-post","javascript","negotiation","reddit"],"created_at":"2025-03-22T07:22:37.852Z","updated_at":"2025-12-30T21:59:54.303Z","avatar_url":"https://github.com/MurikiSaiSrinivas.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# AI Negotiation Game\n\n## 📌 Overview\nThe **AI Negotiation Game** is an interactive, text-based negotiation game where players must persuade an AI-controlled villain to agree to a deal. The game is built using **Google Gemini AI** for dynamic conversations and **Reddit's Devvit API** for integration with Reddit's interactive posts.\n\n## 🎯 Features\n- **AI-Generated Scenarios**: Unique negotiation storylines with dynamic villains.\n- **Limited Responses**: Players can only send **5 messages** with a character limit per message.\n- **Adaptive AI**: The villain responds based on **personality, motivations, and player arguments**.\n- **Final Verdict \u0026 Feedback**: AI determines if the player **won or lost** and provides constructive feedback.\n- **Reddit Integration**: Players can post their negotiation logs on Reddit for community voting.\n\n## 🛠️ Tech Stack\n- **Google Gemini AI** - AI-driven responses and decision-making.\n- **Reddit Devvit API** - Interactive post integration.\n- **TypeScript/JavaScript** - Backend logic for game processing.\n\n## 🚀 Installation \u0026 Setup\n### 1️⃣ Clone the Repository\n```bash\ngit clone https://github.com/MurikiSaiSrinivas/negotiatewithai.git\ncd negotiatewithai\n```\n\n### 2️⃣ Install Dependencies\n```bash\nnpm install\n```\n\n### 3️⃣ Set Up Environment Variables\nAdd the gemini-api-key to the secret storage:\n```bash\ndevvit settings set gemini-api-key\n```\n\n### 4️⃣ Run the Devvit App\n```bash\ndevvit playtest negotiatewithai\n```\n\n### 4️⃣ Open the Devvit App\nURL: [https://www.reddit.com/r/negotiatewithai/?playtest=negotiatewithai](https://www.reddit.com/r/negotiatewithai/?playtest=negotiatewithai)\n\n## 📜 Game Flow\n1. **Start Game** → AI generates a **scenario, villain profile, and first message**.\n2. **Player Negotiates** → Sends up to **5 messages**, villain responds dynamically.\n3. **Final Verdict** → AI determines if the negotiation was successful and provides feedback.\n4. **Share on Reddit** → Players can post the conversation to Reddit for community votes.\n5. **Restart** → Users can start a **new negotiation scenario** anytime.\n\n## 🎮 Example Gameplay\n### **Example Scenario (Generated by AI):**\n```plaintext\nThe year is 2099. A notorious hacker named Razor has stolen classified government files. You, an intelligence officer, must convince Razor to return the files without leaking them.\n\nVillain: \"Well, well, looks like the government finally sent someone who wants to talk. What do you have for me?\"\n```\n### **Player Response:**\n```plaintext\n\"I can offer you partial immunity if you return the files.\"\n```\n### **Villain Response:**\n```plaintext\n\"Hah! Immunity from what? You think I’m scared of your justice system? Give me something real, or this conversation is over.\"\n```\n### **Final Verdict:**\n```plaintext\n\"Fine. You drive a hard bargain, but I’ll take it. Just make sure I get out of here safely.\"\nVerdict: WIN ✅\nFeedback: \"You used logic well, but next time, start with a lower offer to have room to negotiate up.\"\n```\n\n## 🔥 Future Enhancements\n- **Multiplayer Mode** - Team-based negotiations.\n- **Leaderboards** - Ranking system for best negotiators.\n- **More Negotiation Styles** - Aggressive, passive, logical approaches.\n\n---\n🚀 **Ready to negotiate? Start playing now in [r/negotiatewithai](https://www.reddit.com/r/negotiatewithai/)!**\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmurikisaisrinivas%2Fnegotiatewithai","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmurikisaisrinivas%2Fnegotiatewithai","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmurikisaisrinivas%2Fnegotiatewithai/lists"}