Google Search Grounded results, Content Calendar Ideator, Competitor Analysis, and Keyword Researcher
This commit is contained in:
26
alwrity.py
26
alwrity.py
@@ -4,6 +4,11 @@ import json
|
||||
import base64
|
||||
import logging
|
||||
from datetime import datetime
|
||||
import os
|
||||
import json
|
||||
import base64
|
||||
import logging
|
||||
from datetime import datetime
|
||||
|
||||
# Set page config - must be the first Streamlit command
|
||||
st.set_page_config(
|
||||
@@ -59,9 +64,30 @@ from lib.utils.ui_setup import setup_ui
|
||||
from lib.utils.api_key_manager.api_key_manager import APIKeyManager, render
|
||||
from lib.utils.api_key_manager.validation import check_all_api_keys
|
||||
from dotenv import load_dotenv
|
||||
from lib.utils.content_generators import blog_from_keyword, story_input_section, essay_writer, ai_news_writer, ai_finance_ta_writer, write_ai_prod_desc, do_web_research, competitor_analysis
|
||||
from lib.utils.ui_setup import setup_ui, setup_alwrity_ui
|
||||
|
||||
|
||||
def process_folder_for_rag(folder_path):
|
||||
"""Placeholder for the process_folder_for_rag function."""
|
||||
logger.info(f"Processing folder for RAG: {folder_path}")
|
||||
st.write(f"This is a placeholder for processing the folder: {folder_path}")
|
||||
|
||||
|
||||
def save_config(config):
|
||||
"""
|
||||
Saves the provided configuration dictionary to a JSON file specified by the environment variable.
|
||||
"""
|
||||
try:
|
||||
logger.debug(f"Saving configuration to {os.getenv('ALWRITY_CONFIG')}")
|
||||
with open(os.getenv("ALWRITY_CONFIG"), "w") as config_file:
|
||||
json.dump(config, config_file, indent=4)
|
||||
logger.info("Configuration saved successfully")
|
||||
except Exception as e:
|
||||
logger.error(f"Error saving configuration: {str(e)}", exc_info=True)
|
||||
st.error(f"An error occurred while saving the configuration: {e}")
|
||||
|
||||
|
||||
def main():
|
||||
"""Main application entry point."""
|
||||
# Initialize API key manager
|
||||
|
||||
@@ -6,7 +6,7 @@ beautifulsoup4==4.12.2
|
||||
aiohttp>=3.11.11
|
||||
openai>=1.3.7
|
||||
PyPDF2>=3.0.1
|
||||
google-genai>=1.0.0
|
||||
google-genai==1.9.0
|
||||
anthropic>=0.18.1
|
||||
tenacity>=8.2.3
|
||||
tabulate>=0.9.0
|
||||
|
||||
Reference in New Issue
Block a user