Spaces:
Running
Running
chatbot with ai news
Browse files- AINews/daily_summary.md +86 -0
- AINews/monthly_summary.md +222 -0
- AINews/weekly_summary.md +80 -0
- src/langgraph_agentic_ai/UI/streamlitui/__pycache__/display_result.cpython-313.pyc +0 -0
- src/langgraph_agentic_ai/UI/streamlitui/__pycache__/loadui.cpython-313.pyc +0 -0
- src/langgraph_agentic_ai/UI/streamlitui/display_result.py +18 -1
- src/langgraph_agentic_ai/UI/streamlitui/loadui.py +15 -1
- src/langgraph_agentic_ai/__pycache__/main.cpython-313.pyc +0 -0
- src/langgraph_agentic_ai/graph/__pycache__/graph_builder.cpython-313.pyc +0 -0
- src/langgraph_agentic_ai/graph/graph_builder.py +19 -1
- src/langgraph_agentic_ai/main.py +4 -1
- src/langgraph_agentic_ai/nodes/__pycache__/ai_news_node.cpython-313.pyc +0 -0
- src/langgraph_agentic_ai/nodes/ai_news_node.py +98 -0
- src/langgraph_agentic_ai/state/__pycache__/state.cpython-313.pyc +0 -0
- src/langgraph_agentic_ai/state/state.py +4 -1
AINews/daily_summary.md
ADDED
|
@@ -0,0 +1,86 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Daily AI News Summary
|
| 2 |
+
|
| 3 |
+
<think>
|
| 4 |
+
Alright, so I've got this user query where they want me to summarize AI news articles into a specific markdown format. Let me break down what they're asking for.
|
| 5 |
+
|
| 6 |
+
First, they want each news item to include the date in **YYYY-MM-DD** format, specifically in PST timezone. That means I need to convert the given dates from GMT to PST. I remember that PST is GMT-8, so I'll subtract 8 hours from each date. For example, if the date is Wed, 01 Oct 2025 08:34:18 GMT, subtracting 8 hours would make it Tue, 2025-09-30. Wait, no, October 1st minus 8 hours would actually still be September 30th in PST. So, I need to adjust each date accordingly.
|
| 7 |
+
|
| 8 |
+
Next, each summary should be concise, taken from the latest news. The user also wants the news sorted by date, with the latest first. That means I'll arrange the articles starting from the most recent date after converting them all to PST. I should make sure the most recent ones come at the top.
|
| 9 |
+
|
| 10 |
+
The format they want is:
|
| 11 |
+
### [Date]
|
| 12 |
+
- [Summary](URL)
|
| 13 |
+
|
| 14 |
+
I need to ensure each entry starts with the correct date in markdown, followed by a bullet point with the summary linked to the URL. I'll have to extract the essential information from each article's content to craft a brief summary.
|
| 15 |
+
|
| 16 |
+
Looking at the articles, I see topics ranging from AI in maritime, water tech, beauty, healthcare, military training, job cuts, AI video generators, retail forecasting, agriculture, cyber arms race, child safety, insurance regulations, EV infrastructure, robotics investments, and tech deals. Each of these needs a concise summary highlighting the key point.
|
| 17 |
+
|
| 18 |
+
I also notice that some articles have the same date after conversion, so I'll need to order those based on the time, but since the user didn't specify time sorting beyond date, I'll just list them in the order they appear in the input.
|
| 19 |
+
|
| 20 |
+
I should be careful with the URLs to ensure they're correctly formatted as links in markdown. Each summary will be a hyperlink to the source URL.
|
| 21 |
+
|
| 22 |
+
Now, converting each date from GMT to PST:
|
| 23 |
+
|
| 24 |
+
- Wed, 01 Oct 2025 08:34:18 GMT → Tue, 2025-09-30 00:34:18 PST (since 8:34 - 8 hours = 0:34 next day)
|
| 25 |
+
- Tue, 30 Sep 2025 17:35:00 GMT → Tue, 2025-09-30 09:35:00 PST
|
| 26 |
+
- Wed, 01 Oct 2025 10:58:54 GMT → Tue, 2025-09-30 02:58:54 PST
|
| 27 |
+
- Tue, 30 Sep 2025 15:30:00 GMT → Tue, 2025-09-30 07:30:00 PST
|
| 28 |
+
- Wed, 01 Oct 2025 04:02:47 GMT → Tue, 2025-09-30 20:02:47 PST (wait, no, 04:02 GMT - 8 hours is 20:02 on the previous day, so Mon, 2025-09-30? Wait, no. Let me think. If it's 04:02 on Oct 1 GMT, subtracting 8 hours would be 20:02 on Sep 30 PST. So the date remains Sep 30.)
|
| 29 |
+
|
| 30 |
+
Wait, I think I made a mistake here. Let me clarify:
|
| 31 |
+
|
| 32 |
+
For example, a date like Wed, 01 Oct 2025 04:02:47 GMT. Since PST is GMT-8, subtracting 8 hours would bring it to Tue, 30 Sep 2025 20:02:47 PST. So the date becomes 2025-09-30. Similarly, any time on Oct 1 GMT before 8 AM would be on Sep 30 in PST.
|
| 33 |
+
|
| 34 |
+
So I'll adjust each date accordingly and list them in order from latest to earliest. After converting, some articles will be on Sep 30, and one on Oct 1 might actually fall on Sep 30 in PST.
|
| 35 |
+
|
| 36 |
+
Wait, looking back, all the provided dates are either Sep 30 or Oct 1 GMT. After conversion, all the Oct 1 GMT dates before 8 AM PST will be Sep 30 PST. So I'll have multiple articles on Sep 30 and perhaps one or two on Oct 1 if their GMT time is after 8 AM.
|
| 37 |
+
|
| 38 |
+
But looking at the given dates, the latest is Wed, 01 Oct 2025 10:58:54 GMT, which is 02:58 PST on Oct 1, so that would be 2025-10-01. The others are Sep 30.
|
| 39 |
+
|
| 40 |
+
So, I'll sort them with the Oct 1 date first, followed by the Sep 30 ones in the order they were provided.
|
| 41 |
+
|
| 42 |
+
Wait, no. The user said to sort by date, latest first. So after converting, the latest date would be 2025-10-01, followed by 2025-09-30.
|
| 43 |
+
|
| 44 |
+
So I'll have the articles with Oct 1 PST dates first, then the Sep 30 ones.
|
| 45 |
+
|
| 46 |
+
But looking at the converted dates:
|
| 47 |
+
|
| 48 |
+
- 2025-10-01: Only one article (L’Oréal's AI strategy) with date Wed, 01 Oct 2025 10:58:54 GMT, which becomes 02:58 PST, so date is 2025-10-01.
|
| 49 |
+
|
| 50 |
+
All others are Sep 30. So that one will be first, then the rest in the order of their GMT dates, but since they're all Sep 30, I'll list them as per their original order, but ensure they are under the correct date.
|
| 51 |
+
|
| 52 |
+
Wait, but the user provided the articles in a certain order, but I need to sort them by date, latest first. So the Oct 1 article comes first, followed by the Sep 30 ones in their original order, but I should check if any Sep 30 articles have a later time than others.
|
| 53 |
+
|
| 54 |
+
But since the user didn't specify, I'll just list the Oct 1 one first, then the Sep 30 ones in the order they were provided.
|
| 55 |
+
|
| 56 |
+
Now, I'll proceed to summarize each article concisely, ensuring I capture the main point without going into too much detail.
|
| 57 |
+
|
| 58 |
+
For example, the first article about the Maritime CEO Forum discusses AI and digitalization in the maritime industry, focusing on workforce adaptation. So the summary should mention the panel discussion, the impact of AI on maritime operations, and the emphasis on supporting rather than replacing humans.
|
| 59 |
+
|
| 60 |
+
I'll do this for each article, ensuring each summary is a single, clear sentence.
|
| 61 |
+
|
| 62 |
+
Finally, I'll compile them in the specified markdown format, ensuring the dates are correct, the summaries are concise, and the URLs are properly linked.
|
| 63 |
+
|
| 64 |
+
I need to make sure there are no markdown formatting errors, and that each entry is correctly structured under the appropriate date.
|
| 65 |
+
|
| 66 |
+
Double-checking the dates is crucial to ensure they are in PST and correctly formatted as YYYY-MM-DD.
|
| 67 |
+
|
| 68 |
+
I think that's about it. Time to put it all together.
|
| 69 |
+
</think>
|
| 70 |
+
|
| 71 |
+
### 2025-10-01
|
| 72 |
+
- [L'Oréal's AI strategy focuses on integrating artificial intelligence into its operations and products, with Guive Balooch leading the charge in augmented beauty and open innovation.](https://cosmeticsbusiness.com/l-or%C3%A9al-is-fueling-the-future-of-ai)
|
| 73 |
+
|
| 74 |
+
### 2025-09-30
|
| 75 |
+
- [Maritime CEO Forum in Singapore discusses the impact of AI and digitalization on the maritime workforce, emphasizing the need for upskilling and a human-centered approach.](https://splash247.com/maritime-ceo-forum-singapore-ai-digitalisation-and-the-workforce)
|
| 76 |
+
- [Mekorot CEO highlights Israel's leadership in water tech and AI-driven innovation, with global projects expanding in Kazakhstan and Azerbaijan.](https://www.jpost.com/consumerism/article-868824)
|
| 77 |
+
- [Olympus launches an AI-powered application to assist in detecting polyps during colonoscopy, improving detection rates compared to standard methods.](https://www.fiercebiotech.com/medtech/olympus-launches-ai-program-spotting-polyps-during-colonoscopy)
|
| 78 |
+
- [PAULEY and BAE Systems partner on AI and XR training for military applications, focusing on advanced technologies for defense.](https://www.auganix.org/xr-news-pauley-bae-systems-ai-xr)
|
| 79 |
+
- [Lufthansa Group plans to cut 4,000 jobs by 2030, leveraging AI and digitalization to increase efficiency and consolidate operations.](https://www.travelweekly.com/Travel-News/Airline-News/Lufthansa-Group-to-cut-4000-jobs-by-2030-with-help-of-AI)
|
| 80 |
+
- [OpenAI's video generator, Sora, gets a new social media app powered by AI, raising ethical concerns about AI-generated content.](https://www.cnet.com/tech/services-and-software/openais-video-generator-gets-new-social-media-app-with-sora-2)
|
| 81 |
+
- [Retailers increasingly use AI for precision forecasting to navigate supply chain challenges and shifting consumer behaviors.](https://maritime-executive.com/features/retailers-turn-to-ai-for-precision-forecasting-amid-supply-chain-challenges)
|
| 82 |
+
- [Oklahoma State University hosts a conference focusing on AI in agriculture, featuring panels on technology and economic outlooks.](https://www.oklahomafarmreport.com/okfr/2025/09/30/osu-rural-economic-outlook-conference-to-focus-on-hot-topics-in-agriculture)
|
| 83 |
+
- [The cyber arms race in AI highlights the need for the U.S. Department of Defense to develop and critically analyze AI systems for warfare.](https://www.army.mil/article/288851/where_does_the_cyber_arms_race_lead_to_in_the_age_of_artificial_intelligence)
|
| 84 |
+
- [A UK study finds that nearly two-thirds of consumers are willing to pay more for products committed to child safety online.](https://www.mlex.com/mlex/data-privacy-security/articles/2394219/most-users-are-willing-to-pay-for-commitment-to-child-safety-online-uk-consultancy-says)
|
| 85 |
+
- [U.S. regulators are divided on implementing AI rules for insurers, with some states like Colorado leading in algorithmic fairness and AI governance.](https://insurancenewsnet.com/innarticle/states-split-as-naic-regulators-weigh-ai-rules-for-insurers)
|
| 86 |
+
- [InOrbit raises funds to advance its robot orchestration platform, integrating AI and robotics for industrial applications.](https://www.therobotreport.com/globant-invests-inorbit-series-a-funding-advance-robot-orchestration)
|
AINews/monthly_summary.md
ADDED
|
@@ -0,0 +1,222 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Monthly AI News Summary
|
| 2 |
+
|
| 3 |
+
<think>
|
| 4 |
+
Alright, I've got this task to summarize AI news articles into a specific markdown format. Let me go through each step carefully.
|
| 5 |
+
|
| 6 |
+
First, I need to understand the user's request. They want each news item to include the date in **YYYY-MM-DD** format in PST timezone, a concise summary, sorted with the latest first, and a source link. The format should be ### [Date] followed by a bullet point with the summary linked to the URL.
|
| 7 |
+
|
| 8 |
+
I see the user has provided several news articles with their content, URLs, and dates. My job is to process each one, extract the necessary information, and format it correctly.
|
| 9 |
+
|
| 10 |
+
I should start by identifying the dates. The dates are provided in the headers, so I'll need to convert them to PST if they aren't already. Since the user mentioned PST timezone, I need to ensure the dates are accurate in that timezone. But looking at the dates, they seem to be in GMT. I'll have to convert them to PST. For example, if a date is September 6, 2025, in GMT, that would be September 5 in PST if it's after 8 PM GMT.
|
| 11 |
+
|
| 12 |
+
Wait, but the user provided the dates in the format like "Sat, 06 Sep 2025 12:30:11 GMT". So I need to convert these GMT dates to PST. Since PST is UTC-8, I'll subtract 8 hours. Let me calculate each date accordingly.
|
| 13 |
+
|
| 14 |
+
Next, I'll read through each article's content to create a concise summary. I should focus on the key points: who, what, when, where, why. For example, if Melania Trump hosted a meeting, that's the main point. I'll avoid unnecessary details and keep each summary brief.
|
| 15 |
+
|
| 16 |
+
After summarizing each article, I'll sort them by date, ensuring the latest comes first. I'll list them in descending order based on the converted PST dates.
|
| 17 |
+
|
| 18 |
+
I also need to make sure the markdown links are correctly formatted. Each summary sentence should be a hyperlink to the source URL, using the format [Summary](URL).
|
| 19 |
+
|
| 20 |
+
I should check each article for relevance to AI. Some might be about appointments or regulations, which are relevant, so I'll include those. Others might be about company investments or new products, which are also relevant to AI advancements.
|
| 21 |
+
|
| 22 |
+
I'll process each article one by one, starting with the latest date after conversion. Let me list them in order after converting the dates:
|
| 23 |
+
|
| 24 |
+
1. September 30, 2025 (PST)
|
| 25 |
+
2. September 23, 2025 (PST)
|
| 26 |
+
3. September 20, 2025 (PST)
|
| 27 |
+
4. September 18, 2025 (PST)
|
| 28 |
+
5. September 16, 2025 (PST)
|
| 29 |
+
6. September 13, 2025 (PST)
|
| 30 |
+
7. September 11, 2025 (PST)
|
| 31 |
+
8. September 10, 2025 (PST)
|
| 32 |
+
9. September 4, 2025 (PST)
|
| 33 |
+
10. September 3, 2025 (PST)
|
| 34 |
+
|
| 35 |
+
Wait, I think I missed some. Let me recount the dates after conversion.
|
| 36 |
+
|
| 37 |
+
Looking at each article's date in GMT:
|
| 38 |
+
|
| 39 |
+
- Sat, 06 Sep 2025 12:30:11 GMT → Sep 6, 2025, 4:30 AM PST → becomes Sep 5, 2025.
|
| 40 |
+
- Thu, 11 Sep 2025 09:31:10 GMT → Sep 11, 1:31 AM PST → Sep 10, 2025.
|
| 41 |
+
- Sat, 27 Sep 2025 12:30:04 GMT → Sep 27, 4:30 AM PST → Sep 26, 2025.
|
| 42 |
+
- Sat, 13 Sep 2025 12:30:15 GMT → Sep 13, 4:30 AM PST → Sep 12, 2025.
|
| 43 |
+
- Tue, 16 Sep 2025 13:14:04 GMT → Sep 16, 5:14 AM PST → Sep 15, 2025.
|
| 44 |
+
- Tue, 23 Sep 2025 18:03:17 GMT → Sep 23, 10:03 AM PST → same date.
|
| 45 |
+
- Thu, 18 Sep 2025 12:04:00 GMT → Sep 18, 4:04 AM PST → Sep 17, 2025.
|
| 46 |
+
- Wed, 10 Sep 2025 15:50:35 GMT → Sep 10, 7:50 AM PST → same date.
|
| 47 |
+
- Tue, 16 Sep 2025 17:30:43 GMT → Sep 16, 9:30 AM PST → same date.
|
| 48 |
+
- Wed, 24 Sep 2025 03:41:40 GMT → Sep 24, 2025, 7:41 PM PST previous day → Sep 23, 2025.
|
| 49 |
+
- Tue, 30 Sep 2025 14:10:54 GMT → Sep 30, 6:10 AM PST → same date.
|
| 50 |
+
- Sat, 20 Sep 2025 12:30:23 GMT → Sep 20, 4:30 AM PST → Sep 19, 2025.
|
| 51 |
+
- Sat, 20 Sep 2025 17:20:00 GMT → Sep 20, 9:20 AM PST → same date.
|
| 52 |
+
- Wed, 03 Sep 2025 11:42:29 GMT → Sep 3, 3:42 AM PST → Sep 2, 2025.
|
| 53 |
+
|
| 54 |
+
Wait, this is getting complicated. Maybe I should create a list with the original GMT dates and then sort them in PST order.
|
| 55 |
+
|
| 56 |
+
Alternatively, perhaps the user wants the dates in PST without converting, just using the YYYY-MM-DD format based on the original date. Maybe I misinterpreted. The user wrote "Date in **YYYY-MM-DD** format PST timezone", so I think they want the date adjusted to PST.
|
| 57 |
+
|
| 58 |
+
But handling timezones can be tricky. Maybe I should just take the date part from the original GMT date, subtract 8 hours, and adjust the date accordingly if it goes back a day.
|
| 59 |
+
|
| 60 |
+
For example, if the GMT date is 2025-09-06 12:30:11, subtracting 8 hours would make it 2025-09-06 04:30:11 PST, which is still September 6. So the date remains 2025-09-06.
|
| 61 |
+
|
| 62 |
+
But if it's 2025-09-06 00:30:11 GMT, subtracting 8 hours would be 2025-09-05 16:30:11 PST, so the date becomes 2025-09-05.
|
| 63 |
+
|
| 64 |
+
I'll need to apply this to each date.
|
| 65 |
+
|
| 66 |
+
Let me process each article:
|
| 67 |
+
|
| 68 |
+
1. **First Article:**
|
| 69 |
+
- Date: Sat, 06 Sep 2025 12:30:11 GMT
|
| 70 |
+
- PST: 2025-09-06 04:30:11 → Date: 2025-09-06
|
| 71 |
+
|
| 72 |
+
2. **Second Article:**
|
| 73 |
+
- Date: Thu, 11 Sep 2025 09:31:10 GMT
|
| 74 |
+
- PST: 2025-09-11 01:31:10 → Date: 2025-09-11
|
| 75 |
+
|
| 76 |
+
3. **Third Article:**
|
| 77 |
+
- Date: Sat, 27 Sep 2025 12:30:04 GMT
|
| 78 |
+
- PST: 2025-09-27 04:30:04 → Date: 2025-09-27
|
| 79 |
+
|
| 80 |
+
4. **Fourth Article:**
|
| 81 |
+
- Date: Sat, 13 Sep 2025 12:30:15 GMT
|
| 82 |
+
- PST: 2025-09-13 04:30:15 → Date: 2025-09-13
|
| 83 |
+
|
| 84 |
+
5. **Fifth Article:**
|
| 85 |
+
- Date: Sat, 20 Sep 2025 12:30:23 GMT
|
| 86 |
+
- PST: 2025-09-20 04:30:23 → Date: 2025-09-20
|
| 87 |
+
|
| 88 |
+
6. **Sixth Article:**
|
| 89 |
+
- Date: Tue, 16 Sep 2025 13:14:04 GMT
|
| 90 |
+
- PST: 2025-09-16 05:14:04 → Date: 2025-09-16
|
| 91 |
+
|
| 92 |
+
7. **Seventh Article:**
|
| 93 |
+
- Date: Tue, 16 Sep 2025 17:30:43 GMT
|
| 94 |
+
- PST: 2025-09-16 09:30:43 → Date: 2025-09-16
|
| 95 |
+
|
| 96 |
+
8. **Eighth Article:**
|
| 97 |
+
- Date: Thu, 18 Sep 2025 12:04:00 GMT
|
| 98 |
+
- PST: 2025-09-18 04:04:00 → Date: 2025-09-18
|
| 99 |
+
|
| 100 |
+
9. **Ninth Article:**
|
| 101 |
+
- Date: Tue, 23 Sep 2025 18:03:17 GMT
|
| 102 |
+
- PST: 2025-09-23 10:03:17 → Date: 2025-09-23
|
| 103 |
+
|
| 104 |
+
10. **Tenth Article:**
|
| 105 |
+
- Date: Wed, 24 Sep 2025 03:41:40 GMT
|
| 106 |
+
- PST: 2025-09-23 19:41:40 → Date: 2025-09-23
|
| 107 |
+
|
| 108 |
+
11. **Eleventh Article:**
|
| 109 |
+
- Date: Tue, 30 Sep 2025 14:10:54 GMT
|
| 110 |
+
- PST: 2025-09-30 06:10:54 → Date: 2025-09-30
|
| 111 |
+
|
| 112 |
+
12. **Twelfth Article:**
|
| 113 |
+
- Date: Sat, 20 Sep 2025 17:20:00 GMT
|
| 114 |
+
- PST: 2025-09-20 09:20:00 → Date: 2025-09-20
|
| 115 |
+
|
| 116 |
+
13. **Thirteenth Article:**
|
| 117 |
+
- Date: Wed, 03 Sep 2025 11:42:29 GMT
|
| 118 |
+
- PST: 2025-09-03 03:42:29 → Date: 2025-09-03
|
| 119 |
+
|
| 120 |
+
14. **Fourteenth Article:**
|
| 121 |
+
- Date: Thu, 04 Sep 2025 11:59:12 GMT
|
| 122 |
+
- PST: 2025-09-04 03:59:12 → Date: 2025-09-04
|
| 123 |
+
|
| 124 |
+
Wait, I think I missed one. Let me recount the articles:
|
| 125 |
+
|
| 126 |
+
Looking back, the user provided 14 articles. Let me list all dates:
|
| 127 |
+
|
| 128 |
+
1. Sat, 06 Sep 2025 12:30:11 GMT → 2025-09-06
|
| 129 |
+
2. Thu, 11 Sep 2025 09:31:10 GMT → 2025-09-11
|
| 130 |
+
3. Sat, 27 Sep 2025 12:30:04 GMT → 2025-09-27
|
| 131 |
+
4. Sat, 13 Sep 2025 12:30:15 GMT → 2025-09-13
|
| 132 |
+
5. Sat, 20 Sep 2025 12:30:23 GMT → 2025-09-20
|
| 133 |
+
6. Tue, 16 Sep 2025 13:14:04 GMT → 2025-09-16
|
| 134 |
+
7. Tue, 16 Sep 2025 17:30:43 GMT → 2025-09-16
|
| 135 |
+
8. Thu, 18 Sep 2025 12:04:00 GMT → 2025-09-18
|
| 136 |
+
9. Tue, 23 Sep 2025 18:03:17 GMT → 2025-09-23
|
| 137 |
+
10. Wed, 24 Sep 2025 03:41:40 GMT → 2025-09-23
|
| 138 |
+
11. Tue, 30 Sep 2025 14:10:54 GMT → 2025-09-30
|
| 139 |
+
12. Sat, 20 Sep 2025 17:20:00 GMT → 2025-09-20
|
| 140 |
+
13. Wed, 03 Sep 2025 11:42:29 GMT → 2025-09-03
|
| 141 |
+
14. Thu, 04 Sep 2025 11:59:12 GMT → 2025-09-04
|
| 142 |
+
|
| 143 |
+
So, the sorted order from latest to earliest would be:
|
| 144 |
+
|
| 145 |
+
1. 2025-09-30
|
| 146 |
+
2. 2025-09-23
|
| 147 |
+
3. 2025-09-23
|
| 148 |
+
4. 2025-09-20
|
| 149 |
+
5. 2025-09-20
|
| 150 |
+
6. 2025-09-18
|
| 151 |
+
7. 2025-09-16
|
| 152 |
+
8. 2025-09-16
|
| 153 |
+
9. 2025-09-13
|
| 154 |
+
10. 2025-09-11
|
| 155 |
+
11. 2025-09-06
|
| 156 |
+
12. 2025-09-04
|
| 157 |
+
13. 2025-09-04
|
| 158 |
+
14. 2025-09-03
|
| 159 |
+
|
| 160 |
+
Now, I'll go through each article, write a concise summary, and format it with the date and link.
|
| 161 |
+
|
| 162 |
+
Starting with the latest date, 2025-09-30, the article is about the top AI stories in September, including Varo Bank hiring an AI chief.
|
| 163 |
+
|
| 164 |
+
Next, on 2025-09-23, there's an article about states requiring AI policies in schools.
|
| 165 |
+
|
| 166 |
+
Another on 2025-09-23 is about Syngenta using AI in agriculture.
|
| 167 |
+
|
| 168 |
+
Then, on 2025-09-20, there's an article about Nvidia and Intel stocks, and another about Zuckerberg's AI glasses demo fail.
|
| 169 |
+
|
| 170 |
+
On 2025-09-18, Italy passes an AI law.
|
| 171 |
+
|
| 172 |
+
On 2025-09-16, there are two articles: one about Trump's adviser on AI race with China and another about Skift hiring a reporter for AI in travel.
|
| 173 |
+
|
| 174 |
+
On 2025-09-13, OpenAI's nonprofit retaining control.
|
| 175 |
+
|
| 176 |
+
On 2025-09-11, Davies promotes a new CPO.
|
| 177 |
+
|
| 178 |
+
On 2025-09-06, Melania Trump's AI meeting.
|
| 179 |
+
|
| 180 |
+
On 2025-09-04, White House Task Force on AI Education.
|
| 181 |
+
|
| 182 |
+
On 2025-09-03, AI grading in education.
|
| 183 |
+
|
| 184 |
+
I think that covers all the articles. Now, I'll write each summary, ensuring they're concise and capture the main point.
|
| 185 |
+
|
| 186 |
+
I should also ensure that the links are correctly formatted as [Summary](URL).
|
| 187 |
+
|
| 188 |
+
Once all are done, I'll sort them in the correct date order and present them in markdown.
|
| 189 |
+
</think>
|
| 190 |
+
|
| 191 |
+
### 2025-09-30
|
| 192 |
+
- [Varo Bank hires first AI and data chief to lead company-wide AI efforts, plans global expansion using AI capabilities](https://www.fintechfutures.com/ai-in-fintech/september-2025-top-five-ai-stories-of-the-month)
|
| 193 |
+
|
| 194 |
+
### 2025-09-23
|
| 195 |
+
- [At least one state requires schools to have AI policies, with Education Week tracking state-level AI legislation in K-12 education](https://www.edweek.org/technology/which-states-require-schools-to-have-ai-policies/2025/09)
|
| 196 |
+
- [Syngenta partners with Heritable Agriculture to apply AI in vegetable seed selection for growers](https://igrownews.com/syngenta-latest-news/)
|
| 197 |
+
|
| 198 |
+
### 2025-09-20
|
| 199 |
+
- [Nvidia's investment in Intel may strengthen US commitment to AI development, with potential government flexibility in AI matters](https://www.fool.com/investing/2025/09/20/prediction-nvidia-intel-stake-could-be-catalyst/)
|
| 200 |
+
- [Zuckerberg’s AI glasses suffer a live demo hiccup at a major tech event](https://www.foxnews.com/tech/ai-newsletter-zuckerbergs-demo-fail)
|
| 201 |
+
|
| 202 |
+
### 2025-09-18
|
| 203 |
+
- [Italy becomes the first EU country to pass a comprehensive AI law, regulating AI use and imposing penalties for harmful applications](https://www.theguardian.com/world/2025/sep/18/italy-first-in-eu-to-pass-comprehensive-law-regulating-ai)
|
| 204 |
+
|
| 205 |
+
### 2025-09-16
|
| 206 |
+
- [Trump administration adviser frames AI race as existential with China, aiming to shift power to the US](https://www.politico.com/news/2025/09/16/we-dont-want-california-to-set-the-rules-for-ai-across-the-country-trump-adviser-says-00565251)
|
| 207 |
+
- [Skift hires Adriana Lee to cover travel tech and AI](https://talkingbiznews.com/media-news/skift-hires-lee-to-cover-travel-tech-and-artificial-intelligence/)
|
| 208 |
+
|
| 209 |
+
### 2025-09-13
|
| 210 |
+
- [OpenAI’s nonprofit parent retains control, gaining over $100 billion equity stake](https://www.foxnews.com/tech/ai-newsletter-backlash-over-mystery-companys-data-center)
|
| 211 |
+
|
| 212 |
+
### 2025-09-11
|
| 213 |
+
- [Davies appoints John Salt as group chief product officer to strengthen AI technology leadership](https://www.insurancetimes.co.uk/news/davies-promotes-new-group-chief-product-officer-to-strengthen-global-technology-leadership-team/1456345.article)
|
| 214 |
+
|
| 215 |
+
### 2025-09-06
|
| 216 |
+
- [Melania Trump hosts AI meeting with industry leaders, emphasizing responsible AI growth](https://www.foxnews.com/tech/ai-newsletter-melania-trump-puts-ai-front-center)
|
| 217 |
+
|
| 218 |
+
### 2025-09-04
|
| 219 |
+
- [First Lady Melania Trump hosts White House Task Force on AI Education, launches nationwide AI challenge for students](https://www.whitehouse.gov/briefings-statements/2025/09/first-lady-melania-trump-hosts-a-meeting-of-the-white-house-task-force-on-artificial-intelligence-education/)
|
| 220 |
+
|
| 221 |
+
### 2025-09-03
|
| 222 |
+
- [AI grading tool identifies generative AI use in student work, promoting original thinking](https://www.ainvest.com/news/ai-grading-guard-startup-quest-education-human-2509/)
|
AINews/weekly_summary.md
ADDED
|
@@ -0,0 +1,80 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Weekly AI News Summary
|
| 2 |
+
|
| 3 |
+
<think>
|
| 4 |
+
Okay, so I need to help the user by summarizing AI news articles into markdown format. Let me look at the instructions again to make sure I understand what's needed.
|
| 5 |
+
|
| 6 |
+
The user wants each item to include the date in YYYY-MM-DD format in PST timezone, a concise summary, sorted with the latest first, and the source URL as a link. The format should be "### [Date] - [Summary](URL)".
|
| 7 |
+
|
| 8 |
+
First, I'll need to process each article provided. There are several, so I'll go through them one by one.
|
| 9 |
+
|
| 10 |
+
Looking at the first article, the content is about Google partnering with a Bitcoin mining company for AI. The date provided is Fri, 26 Sep 2025 07:07:47 GMT. Since the user wants PST, I need to convert that. GMT is UTC+0, and PST is UTC-8, so subtracting 8 hours from September 26 would make it September 25. Wait, but the date in the content is Sep 26, so maybe I need to adjust that. Let me check: if it's 7 AM GMT on the 26th, PST would be 11 PM on the 25th. So the date should be 2025-09-25.
|
| 11 |
+
|
| 12 |
+
Next, the summary needs to be concise. The article talks about Google acquiring a 5.4% stake in Cipher Mining, which is a Bitcoin mining company, and how this partnership is for AI technology. It mentions increased computing capacity and Texas as a growth center. So the summary should capture that.
|
| 13 |
+
|
| 14 |
+
Moving to the second article about Alibaba's stock surge due to AI ambitions. The date is Thu, 25 Sep 2025 10:47:35 GMT. Converting to PST, that would be the same date, 2025-09-25. The summary should include Alibaba's investment in AI, partnership with Nvidia, and their plans for cloud services.
|
| 15 |
+
|
| 16 |
+
The third article is about GE Aerospace and Merlin Labs collaborating on AI-powered autonomy for aircraft. The date is Fri, 26 Sep 2025 12:47:15 GMT, which converts to 2025-09-25 in PST. The summary should mention the collaboration, the integration of flight systems with autonomy software, and the testing on KC-135 aircraft.
|
| 17 |
+
|
| 18 |
+
The fourth article discusses the UK's mission to safely embed AI, as stated by David Lammy at the UN. The date is Thu, 25 Sep 2025 12:33:31 GMT, so PST date is 2025-09-25. The summary needs to highlight the UK's mission, the risks and benefits of AI, and the call for international cooperation.
|
| 19 |
+
|
| 20 |
+
The fifth article is about Tipalti raising $200 million for AI and global growth. The date is Wed, 24 Sep 2025 13:27:56 GMT, which becomes 2025-09-24 in PST. The summary should include the funding, investment in AI, and the automation features Tipalti offers.
|
| 21 |
+
|
| 22 |
+
The sixth article covers state ed-tech leaders prioritizing AI. The date is Fri, 26 Sep 2025 15:59:08 GMT, converting to 2025-09-25. The summary should mention the shift in priorities, the reasons behind it, and the report's findings.
|
| 23 |
+
|
| 24 |
+
The seventh article is about AI in agriculture, specifically using AI to identify seed varieties. The date is Tue, 30 Sep 2025 16:53:15 GMT, which converts to 2025-09-29 in PST. The summary should talk about Syngenta and Heritable using AI for crop selection.
|
| 25 |
+
|
| 26 |
+
The eighth article is about HeartFlow's FDA clearance for their coronary plaque analysis AI. The date is Wed, 24 Sep 2025 16:00:00 GMT, so PST is 2025-09-24. The summary needs to include the FDA clearance, the improvement in plaque detection, and the significance for clinicians and patients.
|
| 27 |
+
|
| 28 |
+
The ninth article explores whether human and AI intelligence are the same, from Harvard's BKC. The date is Sun, 28 Sep 2025 07:15:00 GMT, which is 2025-09-27 in PST. The summary should discuss the exploration and the implications for understanding human mind and AI development.
|
| 29 |
+
|
| 30 |
+
The tenth article is about California's AI safety law signed by Gavin Newsom. The date is Mon, 29 Sep 2025 20:53:13 GMT, converting to 2025-09-29 in PST. The summary should mention the law, its strength compared to others, and its implications for the tech industry.
|
| 31 |
+
|
| 32 |
+
The eleventh article discusses AI and digitalization in the maritime workforce. The date is Wed, 01 Oct 2025 08:34:18 GMT, which is 2025-09-30 in PST. The summary should cover the impact of AI on maritime operations and the need for workforce adaptation.
|
| 33 |
+
|
| 34 |
+
The twelfth article is about Mekorot's leadership in water tech using AI. The date is Tue, 30 Sep 2025 17:35:00 GMT, converting to 2025-09-29 in PST. The summary should include their global projects and the role of AI in their innovations.
|
| 35 |
+
|
| 36 |
+
The thirteenth article is about the University of Kansas hosting an AI week with Google. The date is Fri, 26 Sep 2025 23:35:52 GMT, which becomes 2025-09-25 in PST. The summary should mention the event, partnership with Google, and KU's intentional approach to AI adoption.
|
| 37 |
+
|
| 38 |
+
The fourteenth article is about Anthropic releasing Claude Sonnet 4.5 for autonomous tasks. The date is Mon, 29 Sep 2025 21:56:15 GMT, converting to 2025-09-29 in PST. The summary should highlight the model's capabilities in building software and business tasks.
|
| 39 |
+
|
| 40 |
+
The fifteenth article covers various top tech news including HSBC, IBM, and Microsoft. The date is Sun, 28 Sep 2025 09:25:35 GMT, which is 2025-09-27 in PST. The summary should mention the bond-trading algorithm improvement and Microsoft's strategy on Azure.
|
| 41 |
+
|
| 42 |
+
Now, I need to sort all these articles by date, latest first. So I'll list them from 2025-09-30 down to 2025-09-24.
|
| 43 |
+
|
| 44 |
+
I also need to ensure each summary is concise and captures the main points without being too lengthy. Each should be a single sentence, but if needed, two sentences are acceptable as long as they're succinct.
|
| 45 |
+
|
| 46 |
+
I should also check that all URLs are correctly formatted as links in markdown. Each summary will be in the format "- [Summary](URL)" under the appropriate date header.
|
| 47 |
+
|
| 48 |
+
I need to make sure that the dates are correctly converted to PST. Let me double-check a few to ensure accuracy. For example, the article with date Wed, 01 Oct 2025 in GMT is actually September 30 in PST because October 1st 8 AM GMT is September 30 0:00 PST plus 8 hours, making it still September 30.
|
| 49 |
+
|
| 50 |
+
Finally, I'll compile all the processed articles into the required markdown format, ensuring that the latest date comes first and each entry follows the specified structure.
|
| 51 |
+
</think>
|
| 52 |
+
|
| 53 |
+
### 2025-09-30
|
| 54 |
+
- [Maritime CEO Forum Singapore discusses AI's impact on workforce adaptation in the shipping industry](https://splash247.com/maritime-ceo-forum-singapore-ai-digitalisation-and-the-workforce/)
|
| 55 |
+
|
| 56 |
+
### 2025-09-29
|
| 57 |
+
- [Mekorot CEO highlights Israel's leadership in water tech and AI-driven global projects](https://www.jpost.com/consumerism/article-868824)
|
| 58 |
+
- [California Governor Gavin Newsom signs major AI safety law](https://www.nytimes.com/2025/09/29/technology/california-ai-safety-law.html)
|
| 59 |
+
- [Anthropic releases Claude Sonnet 4.5, an AI model for autonomous software development](https://fortune.com/2025/09/29/anthropic-releases-claude-sonnet-4-5-a-model-it-says-can-build-software-and-accomplish-business-tasks-autonomously/)
|
| 60 |
+
|
| 61 |
+
### 2025-09-28
|
| 62 |
+
- [The rise of algorithmic agriculture with AI identifying top-performing seed varieties](https://www.artificialintelligence-news.com/news/the-rise-of-algorithmic-agriculture-ai-steps-in/)
|
| 63 |
+
|
| 64 |
+
### 2025-09-27
|
| 65 |
+
- [Harvard’s BKC explores the equivalence of human and AI computational intelligence](https://www.forbes.com/sites/lanceeliot/2025/09/28/harvards-bkc-explores-whether-human-intelligence-and-ai-computational-intelligence-are-actually-the-same)
|
| 66 |
+
- [Top tech news: HSBC and IBM improve bond-trading algorithms with quantum computing](https://ts2.tech/en/billion-dollar-ai-bets-and-biotech-breakthroughs-top-tech-news-sept-27-28-2025/)
|
| 67 |
+
|
| 68 |
+
### 2025-09-26
|
| 69 |
+
- [Google secretly partners with Bitcoin mining company for AI technology](https://pintu.co.id/en/news/210787-google-secretly-partnered-with-bitcoin-mining-company-for-ai-technology-here-are-the-details)
|
| 70 |
+
- [GE Aerospace and Merlin Labs collaborate on AI-powered autonomy for aircraft](https://thedefensepost.com/2025/09/26/ge-merlin-ai-flight/)
|
| 71 |
+
- [University of Kansas partners with Google to host its first campus-wide AI week](https://www.govtech.com/education/higher-ed/university-of-kansas-google-to-host-first-campus-ai-week)
|
| 72 |
+
|
| 73 |
+
### 2025-09-25
|
| 74 |
+
- [Alibaba stock surges on AI ambitions and partnership with Nvidia](https://ts2.tech/en/alibabas-53-billion-ai-blitz-stock-soars-on-nvidia-pact-and-global-cloud-push/)
|
| 75 |
+
- [UK’s mission to safely embed AI in society, as told by Deputy PM David Lammy at the UN](https://www.publictechnology.net/2025/09/25/news/uks-mission-is-embedding-ai-safely-in-society-lammy-tells-un/)
|
| 76 |
+
- [State ed-tech leaders prioritize AI for the first time](https://marketbrief.edweek.org/education-market/ai-tops-list-of-state-ed-tech-priorities-for-first-time-new-report-shows/2025/09)
|
| 77 |
+
|
| 78 |
+
### 2025-09-24
|
| 79 |
+
- [Tipalti raises $200 million to expand AI and global growth](https://www.ynetnews.com/business/article/rjxgxuznxx)
|
| 80 |
+
- [HeartFlow’s updated AI for coronary plaque analysis receives FDA clearance](https://www.fiercebiotech.com/medtech/heartflows-updated-coronary-plaque-analysis-ai-nets-fda-clearance-more-payer-coverage)
|
src/langgraph_agentic_ai/UI/streamlitui/__pycache__/display_result.cpython-313.pyc
CHANGED
|
Binary files a/src/langgraph_agentic_ai/UI/streamlitui/__pycache__/display_result.cpython-313.pyc and b/src/langgraph_agentic_ai/UI/streamlitui/__pycache__/display_result.cpython-313.pyc differ
|
|
|
src/langgraph_agentic_ai/UI/streamlitui/__pycache__/loadui.cpython-313.pyc
CHANGED
|
Binary files a/src/langgraph_agentic_ai/UI/streamlitui/__pycache__/loadui.cpython-313.pyc and b/src/langgraph_agentic_ai/UI/streamlitui/__pycache__/loadui.cpython-313.pyc differ
|
|
|
src/langgraph_agentic_ai/UI/streamlitui/display_result.py
CHANGED
|
@@ -40,4 +40,21 @@ class DisplayResultStreamlit:
|
|
| 40 |
st.write("Tool Call End")
|
| 41 |
elif type(message)==AIMessage and message.content:
|
| 42 |
with st.chat_message("assistant"):
|
| 43 |
-
st.write(message.content)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 40 |
st.write("Tool Call End")
|
| 41 |
elif type(message)==AIMessage and message.content:
|
| 42 |
with st.chat_message("assistant"):
|
| 43 |
+
st.write(message.content)
|
| 44 |
+
|
| 45 |
+
elif usecase == "AI News":
|
| 46 |
+
frequency = self.user_message
|
| 47 |
+
with st.spinner("Fetching and summarizing news... ⏳"):
|
| 48 |
+
result = graph.invoke({"messages": frequency})
|
| 49 |
+
try:
|
| 50 |
+
# Read the markdown file
|
| 51 |
+
AI_NEWS_PATH = f"./AINews/{frequency.lower()}_summary.md"
|
| 52 |
+
with open(AI_NEWS_PATH, "r") as file:
|
| 53 |
+
markdown_content = file.read()
|
| 54 |
+
|
| 55 |
+
# Display the markdown content in Streamlit
|
| 56 |
+
st.markdown(markdown_content, unsafe_allow_html=True)
|
| 57 |
+
except FileNotFoundError:
|
| 58 |
+
st.error(f"News Not Generated or File not found: {AI_NEWS_PATH}")
|
| 59 |
+
except Exception as e:
|
| 60 |
+
st.error(f"An error occurred: {str(e)}")
|
src/langgraph_agentic_ai/UI/streamlitui/loadui.py
CHANGED
|
@@ -12,6 +12,8 @@ class LoadStreamlitUI:
|
|
| 12 |
def load_streamlit_ui(self):
|
| 13 |
st.set_page_config(page_title= "🤖 " + self.config.get_page_title(), layout="wide")
|
| 14 |
st.header("🤖 " + self.config.get_page_title())
|
|
|
|
|
|
|
| 15 |
|
| 16 |
|
| 17 |
with st.sidebar:
|
|
@@ -34,11 +36,23 @@ class LoadStreamlitUI:
|
|
| 34 |
## USecase selection
|
| 35 |
self.user_controls["selected_usecase"]=st.selectbox("Select Usecases",usecase_options)
|
| 36 |
|
| 37 |
-
if self.user_controls["selected_usecase"] == "Chatbot with WebSearch":
|
| 38 |
os.environ["TAVILY_API_KEY"]=self.user_controls["TAVILY_API_KEY"]= st.session_state['TAVILY_API_KEY']=st.text_input("TAVILY API KEY",type="password")
|
| 39 |
|
| 40 |
if not self.user_controls["TAVILY_API_KEY"]:
|
| 41 |
st.warning("⚠️ Please enter your TAVILY_API_KEY key to proceed. Don't have? refer : https://app.tavily.com/home")
|
| 42 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 43 |
|
| 44 |
return self.user_controls
|
|
|
|
| 12 |
def load_streamlit_ui(self):
|
| 13 |
st.set_page_config(page_title= "🤖 " + self.config.get_page_title(), layout="wide")
|
| 14 |
st.header("🤖 " + self.config.get_page_title())
|
| 15 |
+
st.session_state.timeframe = ''
|
| 16 |
+
st.session_state.IsFetchButtonClicked = False
|
| 17 |
|
| 18 |
|
| 19 |
with st.sidebar:
|
|
|
|
| 36 |
## USecase selection
|
| 37 |
self.user_controls["selected_usecase"]=st.selectbox("Select Usecases",usecase_options)
|
| 38 |
|
| 39 |
+
if self.user_controls["selected_usecase"] == "Chatbot with WebSearch" or self.user_controls["selected_usecase"] == "AI News":
|
| 40 |
os.environ["TAVILY_API_KEY"]=self.user_controls["TAVILY_API_KEY"]= st.session_state['TAVILY_API_KEY']=st.text_input("TAVILY API KEY",type="password")
|
| 41 |
|
| 42 |
if not self.user_controls["TAVILY_API_KEY"]:
|
| 43 |
st.warning("⚠️ Please enter your TAVILY_API_KEY key to proceed. Don't have? refer : https://app.tavily.com/home")
|
| 44 |
|
| 45 |
+
if self.user_controls['selected_usecase']=="AI News":
|
| 46 |
+
st.subheader("📰 AI News Explorer ")
|
| 47 |
+
|
| 48 |
+
with st.sidebar:
|
| 49 |
+
time_frame = st.selectbox(
|
| 50 |
+
"📅 Select Time Frame",
|
| 51 |
+
["Daily", "Weekly", "Monthly"],
|
| 52 |
+
index=0
|
| 53 |
+
)
|
| 54 |
+
if st.button("🔍 Fetch Latest AI News", use_container_width=True):
|
| 55 |
+
st.session_state.IsFetchButtonClicked = True
|
| 56 |
+
st.session_state.timeframe = time_frame
|
| 57 |
|
| 58 |
return self.user_controls
|
src/langgraph_agentic_ai/__pycache__/main.cpython-313.pyc
CHANGED
|
Binary files a/src/langgraph_agentic_ai/__pycache__/main.cpython-313.pyc and b/src/langgraph_agentic_ai/__pycache__/main.cpython-313.pyc differ
|
|
|
src/langgraph_agentic_ai/graph/__pycache__/graph_builder.cpython-313.pyc
CHANGED
|
Binary files a/src/langgraph_agentic_ai/graph/__pycache__/graph_builder.cpython-313.pyc and b/src/langgraph_agentic_ai/graph/__pycache__/graph_builder.cpython-313.pyc differ
|
|
|
src/langgraph_agentic_ai/graph/graph_builder.py
CHANGED
|
@@ -6,7 +6,7 @@ from src.langgraph_agentic_ai.nodes.basic_chatbot_node import BasicChatbotNode
|
|
| 6 |
from src.langgraph_agentic_ai.tools.search_tool import get_tools,create_tool_node
|
| 7 |
from langgraph.prebuilt import tools_condition,ToolNode
|
| 8 |
from src.langgraph_agentic_ai.nodes.chatbot_with_tool_node import chatbotwithToolNode
|
| 9 |
-
|
| 10 |
|
| 11 |
|
| 12 |
class GraphBuilder:
|
|
@@ -60,6 +60,21 @@ class GraphBuilder:
|
|
| 60 |
self.graph_builder.add_edge("tools","chatbot")
|
| 61 |
self.graph_builder.add_edge("chatbot",END)
|
| 62 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 63 |
def setup_graph(self,usecase:str):
|
| 64 |
"""
|
| 65 |
Sets up the graph for the selected use case
|
|
@@ -69,6 +84,9 @@ class GraphBuilder:
|
|
| 69 |
self.basic_chatbot_build_graph()
|
| 70 |
if usecase == "Chatbot with WebSearch":
|
| 71 |
self.chatbot_with_tools_build_graph()
|
|
|
|
|
|
|
|
|
|
| 72 |
|
| 73 |
return self.graph_builder.compile()
|
| 74 |
|
|
|
|
| 6 |
from src.langgraph_agentic_ai.tools.search_tool import get_tools,create_tool_node
|
| 7 |
from langgraph.prebuilt import tools_condition,ToolNode
|
| 8 |
from src.langgraph_agentic_ai.nodes.chatbot_with_tool_node import chatbotwithToolNode
|
| 9 |
+
from src.langgraph_agentic_ai.nodes.ai_news_node import AiNewsNode
|
| 10 |
|
| 11 |
|
| 12 |
class GraphBuilder:
|
|
|
|
| 60 |
self.graph_builder.add_edge("tools","chatbot")
|
| 61 |
self.graph_builder.add_edge("chatbot",END)
|
| 62 |
|
| 63 |
+
|
| 64 |
+
|
| 65 |
+
def ai_news_builder_graph(self):
|
| 66 |
+
|
| 67 |
+
ai_news_node=AiNewsNode(self.llm)
|
| 68 |
+
|
| 69 |
+
self.graph_builder.add_node("fetch_news",ai_news_node.fetch_news)
|
| 70 |
+
self.graph_builder.add_node("summarize_news",ai_news_node.summarize_news)
|
| 71 |
+
self.graph_builder.add_node("save_result",ai_news_node.save_result)
|
| 72 |
+
|
| 73 |
+
self.graph_builder.set_entry_point("fetch_news")
|
| 74 |
+
self.graph_builder.add_edge("fetch_news","summarize_news")
|
| 75 |
+
self.graph_builder.add_edge("summarize_news","save_result")
|
| 76 |
+
self.graph_builder.add_edge("save_result",END)
|
| 77 |
+
|
| 78 |
def setup_graph(self,usecase:str):
|
| 79 |
"""
|
| 80 |
Sets up the graph for the selected use case
|
|
|
|
| 84 |
self.basic_chatbot_build_graph()
|
| 85 |
if usecase == "Chatbot with WebSearch":
|
| 86 |
self.chatbot_with_tools_build_graph()
|
| 87 |
+
if usecase == "AI News":
|
| 88 |
+
self.ai_news_builder_graph()
|
| 89 |
+
|
| 90 |
|
| 91 |
return self.graph_builder.compile()
|
| 92 |
|
src/langgraph_agentic_ai/main.py
CHANGED
|
@@ -21,7 +21,10 @@ def load_langgraph_agenticai_app():
|
|
| 21 |
st.error("Error: Failed to load user input from the UI.")
|
| 22 |
return
|
| 23 |
|
| 24 |
-
|
|
|
|
|
|
|
|
|
|
| 25 |
|
| 26 |
if user_message:
|
| 27 |
try:
|
|
|
|
| 21 |
st.error("Error: Failed to load user input from the UI.")
|
| 22 |
return
|
| 23 |
|
| 24 |
+
if st.session_state.IsFetchButtonClicked:
|
| 25 |
+
user_message= st.session_state.timeframe
|
| 26 |
+
else:
|
| 27 |
+
user_message = st.chat_input("Enter your message:")
|
| 28 |
|
| 29 |
if user_message:
|
| 30 |
try:
|
src/langgraph_agentic_ai/nodes/__pycache__/ai_news_node.cpython-313.pyc
ADDED
|
Binary file (4.45 kB). View file
|
|
|
src/langgraph_agentic_ai/nodes/ai_news_node.py
ADDED
|
@@ -0,0 +1,98 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
from requests import Response
|
| 2 |
+
from tavily import TavilyClient
|
| 3 |
+
from langchain_core.prompts import ChatPromptTemplate
|
| 4 |
+
from urllib3 import response
|
| 5 |
+
|
| 6 |
+
class AiNewsNode:
|
| 7 |
+
def __init__(self,llm):
|
| 8 |
+
"""
|
| 9 |
+
Intialize the AINewsNode with API Keys for Tavily and Groq
|
| 10 |
+
"""
|
| 11 |
+
|
| 12 |
+
self.tavily = TavilyClient()
|
| 13 |
+
self.llm = llm
|
| 14 |
+
|
| 15 |
+
self.state = {}
|
| 16 |
+
|
| 17 |
+
|
| 18 |
+
def fetch_news(self,state:dict) -> dict:
|
| 19 |
+
"""
|
| 20 |
+
Fetch AI news based on the specified frequency.
|
| 21 |
+
|
| 22 |
+
Args:
|
| 23 |
+
state (dict) : The state dictionary containing the 'frequency'.
|
| 24 |
+
|
| 25 |
+
Returns:
|
| 26 |
+
dict : The state dictionary containing the 'news'.
|
| 27 |
+
"""
|
| 28 |
+
|
| 29 |
+
frequency = state['messages'][-1].content.lower()
|
| 30 |
+
self.state['frequency'] = frequency
|
| 31 |
+
time_range_map = {'daily':'d','weekly':'w','monthly':'m','yearly':'y'}
|
| 32 |
+
days_map = {'daily':1,'weekly':7,'monthly':30,'yearly':365}
|
| 33 |
+
|
| 34 |
+
resp = self.tavily.search(
|
| 35 |
+
query=f"Top artificial intelligence (AI) technology news globally",
|
| 36 |
+
topic="news",
|
| 37 |
+
time_range=time_range_map[frequency],
|
| 38 |
+
include_answer="advanced",
|
| 39 |
+
max_results=15,
|
| 40 |
+
days=days_map[frequency],
|
| 41 |
+
# include_domain=["techcrunch.come","venturebeat.com/ai,..."]
|
| 42 |
+
)
|
| 43 |
+
|
| 44 |
+
state['news_data'] = resp.get('results', [])
|
| 45 |
+
self.state['news_data'] = state['news_data']
|
| 46 |
+
return state
|
| 47 |
+
|
| 48 |
+
def summarize_news(self,state:dict) -> dict:
|
| 49 |
+
"""
|
| 50 |
+
Summarize the fetched news using an LLM.
|
| 51 |
+
|
| 52 |
+
Args:
|
| 53 |
+
state (dict) : The state dictionary containing the 'news_data'.
|
| 54 |
+
|
| 55 |
+
Returns:
|
| 56 |
+
dict : Updated state with 'summary' key containing the summarized news.
|
| 57 |
+
"""
|
| 58 |
+
news_item = state['news_data']
|
| 59 |
+
|
| 60 |
+
prompt_template = ChatPromptTemplate.from_messages([
|
| 61 |
+
(
|
| 62 |
+
"system","""Summarize AI news articles into markdown format. For each item include:
|
| 63 |
+
- Date in **YYYY-MM-DD** format PST timezone
|
| 64 |
+
- Concise sentences summary from latest news
|
| 65 |
+
- Sort news by data wise (latest first)
|
| 66 |
+
- source URL as link
|
| 67 |
+
|
| 68 |
+
Use format:
|
| 69 |
+
### [Date]
|
| 70 |
+
- [Summary](URL)
|
| 71 |
+
|
| 72 |
+
"""
|
| 73 |
+
),
|
| 74 |
+
("user","Articles: \n {articles}")
|
| 75 |
+
])
|
| 76 |
+
|
| 77 |
+
articles_str = "\n\n".join([
|
| 78 |
+
f"Content: {item.get('content','')}\nURL : {item.get('url','')}\nDate: {item.get('published_date','')}"
|
| 79 |
+
for item in news_item
|
| 80 |
+
])
|
| 81 |
+
|
| 82 |
+
response= self.llm.invoke(prompt_template.format(articles=articles_str))
|
| 83 |
+
state['summary'] = response.content
|
| 84 |
+
self.state['summary']= state['summary']
|
| 85 |
+
return self.state
|
| 86 |
+
|
| 87 |
+
def save_result(self,state):
|
| 88 |
+
frequency = self.state['frequency']
|
| 89 |
+
summary = self.state['summary']
|
| 90 |
+
filename = f"./AINews/{frequency}_summary.md"
|
| 91 |
+
with open(filename,'w') as f :
|
| 92 |
+
f.write(f'# {frequency.capitalize()} AI News Summary\n\n')
|
| 93 |
+
f.write(summary)
|
| 94 |
+
|
| 95 |
+
self.state['filename'] = filename
|
| 96 |
+
return self.state
|
| 97 |
+
|
| 98 |
+
|
src/langgraph_agentic_ai/state/__pycache__/state.cpython-313.pyc
CHANGED
|
Binary files a/src/langgraph_agentic_ai/state/__pycache__/state.cpython-313.pyc and b/src/langgraph_agentic_ai/state/__pycache__/state.cpython-313.pyc differ
|
|
|
src/langgraph_agentic_ai/state/state.py
CHANGED
|
@@ -1,5 +1,5 @@
|
|
| 1 |
from typing import Annotated
|
| 2 |
-
from typing_extensions import TypedDict, List
|
| 3 |
from langgraph.graph.message import add_messages
|
| 4 |
|
| 5 |
class State(TypedDict):
|
|
@@ -9,3 +9,6 @@ class State(TypedDict):
|
|
| 9 |
"""
|
| 10 |
|
| 11 |
messages: Annotated[List,add_messages]
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
from typing import Annotated
|
| 2 |
+
from typing_extensions import TypedDict, List, NotRequired
|
| 3 |
from langgraph.graph.message import add_messages
|
| 4 |
|
| 5 |
class State(TypedDict):
|
|
|
|
| 9 |
"""
|
| 10 |
|
| 11 |
messages: Annotated[List,add_messages]
|
| 12 |
+
news_data: NotRequired[List]
|
| 13 |
+
summary: NotRequired[str]
|
| 14 |
+
filename: NotRequired[str]
|