{"id":21125415,"url":"https://github.com/cs2219/prompt_engineering","last_synced_at":"2026-05-21T10:03:52.667Z","repository":{"id":263235113,"uuid":"889527279","full_name":"CS2219/prompt_engineering","owner":"CS2219","description":"Prompt engineering techniques with streamlit and openai","archived":false,"fork":false,"pushed_at":"2024-11-17T06:40:09.000Z","size":4,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-01-21T05:28:20.458Z","etag":null,"topics":["openai-api","prompt-engineering","python","streamlit"],"latest_commit_sha":null,"homepage":"https://github.com/CS2219/prompt_engineering","language":"Python","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/CS2219.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":"2024-11-16T14:59:12.000Z","updated_at":"2024-11-17T06:44:10.000Z","dependencies_parsed_at":"2024-11-17T07:39:09.114Z","dependency_job_id":null,"html_url":"https://github.com/CS2219/prompt_engineering","commit_stats":null,"previous_names":["cs2219/prompt_engineering"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CS2219%2Fprompt_engineering","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CS2219%2Fprompt_engineering/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CS2219%2Fprompt_engineering/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CS2219%2Fprompt_engineering/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CS2219","download_url":"https://codeload.github.com/CS2219/prompt_engineering/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243573163,"owners_count":20312879,"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":["openai-api","prompt-engineering","python","streamlit"],"created_at":"2024-11-20T04:33:34.289Z","updated_at":"2026-05-21T10:03:47.635Z","avatar_url":"https://github.com/CS2219.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# prompt_engineering\n**Interactive Prompt Testing: Enter custom prompts and see real-time responses from OpenAI's GPT models.**\nPrompt Engineering Techniques: Learn and apply techniques like:\nRole-playing and Persona Assignment\nChain-of-Thought Prompting\nFew-shot and Zero-shot Learning\nIterative Refinement\nStreamlit-Based UI: A simple, user-friendly interface to interact with the API.\nEducational Content: Includes explanations and examples of effective prompt engineering.\n\n**Installation**\nFollow these steps to get the app up and running:\n\n**1. Clone the Repository**\n```python\ngit clone https://github.com/your-username/prompt-engineering.git\ncd prompt-engineering\n\n```\n**2. Install Dependencies**\nMake sure you have Python 3.7 or later. Install the required libraries:\n```python\npip install -r requirements.txt\n\n```\n**3. Set Up OpenAI API Key**\nCreate a .env file in the root directory and add your OpenAI API key:\n```python\nOPENAI_API_KEY=your-openai-api-key-here\n```\nAlternatively, you can set the environment variable directly in your terminal:\n```python\nexport OPENAI_API_KEY=your-openai-api-key-here\n```\n**4. Run the App**\nRun the Streamlit app locally:\n```python\nstreamlit run app.py\n```\nThe app will open in your default browser at http://localhost:8501.\n\n**Usage**\nEnter a prompt in the text input field (e.g., \"Write a story about a mischievous dragon.\").\nClick the \"Generate\" button to get a response from the OpenAI API.\nExperiment with different prompt engineering techniques explained in the app.\n\n**Resources**\nHere are some useful resources to learn more about OpenAI’s API and prompt engineering:\n\n📖 OpenAI API Documentation\n💡 OpenAI Cookbook\n📚 Introduction to Prompt Engineering\n🎥 YouTube: Practical Prompt Engineering Techniques\n🛠 Streamlit Documentation","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcs2219%2Fprompt_engineering","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcs2219%2Fprompt_engineering","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcs2219%2Fprompt_engineering/lists"}