@aikeytake/social-automation 2.0.9 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,67 @@
1
+ // Sources configuration - bundled directly, no filesystem access needed
2
+ export default {
3
+ rssFeeds: [
4
+ { name: "TechCrunch AI", url: "https://techcrunch.com/category/artificial-intelligence/feed/", category: "ai-news", enabled: true },
5
+ { name: "The Gradient", url: "https://thegradient.pub/rss/", category: "ai-research", enabled: true },
6
+ { name: "MIT Technology Review AI", url: "https://www.technologyreview.com/feed/", category: "tech-news", enabled: true },
7
+ { name: "OpenAI Blog", url: "https://openai.com/blog/rss.xml", category: "company-news", enabled: true },
8
+ { name: "Anthropic Blog", url: "https://raw.githubusercontent.com/Olshansk/rss-feeds/main/feeds/feed_anthropic.xml", category: "company-news", enabled: true },
9
+ { name: "Claude Blog", url: "https://raw.githubusercontent.com/Olshansk/rss-feeds/main/feeds/feed_claude.xml", category: "company-news", enabled: true },
10
+ { name: "Google AI Blog", url: "https://blog.google/technology/ai/rss/", category: "company-news", enabled: true },
11
+ { name: "DeepMind Blog", url: "https://deepmind.google/blog/rss.xml", category: "research", enabled: true },
12
+ { name: "Hugging Face Blog", url: "https://huggingface.co/blog/feed.xml", category: "ml-frameworks", enabled: true },
13
+ { name: "Meta Engineering", url: "https://engineering.fb.com/feed/", category: "company-engineering", enabled: true },
14
+ { name: "Netflix Tech Blog", url: "https://medium.com/feed/netflix-techblog", category: "company-engineering", enabled: true },
15
+ { name: "AWS Machine Learning Blog", url: "https://aws.amazon.com/blogs/machine-learning/feed/", category: "cloud-ai", enabled: true },
16
+ { name: "Microsoft AI Blog", url: "https://blogs.microsoft.com/ai/feed/", category: "company-news", enabled: true },
17
+ { name: "NVIDIA Technical Blog", url: "https://blogs.nvidia.com/feed/", category: "company-engineering", enabled: true },
18
+ { name: "LinkedIn Engineering", url: "https://engineering.linkedin.com/blog.rss", category: "company-engineering", enabled: true },
19
+ { name: "arXiv AI", url: "https://rss.arxiv.org/rss/cs.AI", category: "research-papers", enabled: true },
20
+ { name: "arXiv Machine Learning", url: "https://rss.arxiv.org/rss/cs.LG", category: "research-papers", enabled: true }
21
+ ],
22
+ linkedin_browser: { enabled: true, accounts: ["julienchaumond"], maxPostsPerAccount: 5, maxAgeHours: 48, delayBetweenAccountsMs: 10000 },
23
+ apiSources: [
24
+ {
25
+ id: "goodailist", name: "Good AI List", enabled: true, weight: 0.5,
26
+ request: { url: "https://goodailist.com/api/repos", method: "GET", params: { page: 1, limit: 100, sort: "star_1d", order: "desc" } },
27
+ response: { itemsPath: "repos" },
28
+ mapping: {
29
+ title: "repo", link: "https://github.com/{repo}", summary: "description", content: "description",
30
+ author: { field: "repo", split: "/", index: 0 }, pubDate: "created_at", category: "category",
31
+ tags: { field: "keywords", split: "," }, "engagement.upvotes": "star_1d",
32
+ "metadata.stars": "stars", "metadata.star_7d": "star_7d", "metadata.forks": "forks", "metadata.language": "language"
33
+ }
34
+ },
35
+ {
36
+ id: "producthunt", name: "Product Hunt", enabled: true,
37
+ auth: { type: "oauth2_client_credentials", tokenUrl: "https://api.producthunt.com/v2/oauth/token", clientIdEnv: "PRODUCT_HUNT_API_KEY", clientSecretEnv: "PRODUCT_HUNT_API_SECRET" },
38
+ request: {
39
+ url: "https://api.producthunt.com/v2/api/graphql", method: "POST",
40
+ graphql: { query: "query($first: Int!, $order: PostsOrder!, $postedAfter: DateTime!) { posts(first: $first, order: $order, postedAfter: $postedAfter) { edges { node { name tagline description url website votesCount commentsCount createdAt topics { edges { node { name } } } user { name } } } } }", variables: { first: 30, order: "VOTES" } },
41
+ computedVariables: { postedAfter: { type: "daysAgo", days: 7 } }
42
+ },
43
+ response: { itemsPath: "data.posts.edges", itemUnwrap: "node" },
44
+ filter: { field: "votesCount", min: 50 },
45
+ mapping: {
46
+ title: "name", link: "url", summary: "tagline", content: ["tagline", "description"],
47
+ author: { path: "user.name" }, pubDate: "createdAt",
48
+ category: { path: "topics.edges", map: "node.name", index: 0 },
49
+ tags: { path: "topics.edges", map: "node.name" },
50
+ "engagement.upvotes": "votesCount", "engagement.comments": "commentsCount", "metadata.website": "website"
51
+ }
52
+ }
53
+ ],
54
+ linkedin: { profilesFile: "/home/vankhoa/projects/aikeytake/workspace/marketing/linkedin_kol_clean.json", enabled: true, batchSize: 8, budgetPerRun: 25, checkIntervalHours: 24, timeRange: "w", resultsPerBatch: 10, enrichContent: true, enrichConcurrency: 5 },
55
+ youtube: { channels: [{ name: "Andrej Karpathy", channelId: "UC之以A5_BH8q-8v6Fn4qF5A", enabled: false }, { name: "Yannic Kilcher", channelId: "UC媒介ucH6r6tiKnM2LTC1cw", enabled: false }], enabled: false },
56
+ keywords: {
57
+ primary: ["artificial intelligence", "machine learning", "deep learning", "LLM", "GPT", "Claude", "transformer", "neural network", "AGI", "AI research"],
58
+ secondary: ["computer vision", "NLP", "reinforcement learning", "diffusion model", "multimodal", "fine-tuning", "RAG", "agent", "LangChain", "vector database"]
59
+ },
60
+ filtering: { minEngagementScore: 10, maxAgeHours: 48, deduplicationWindow: 72 },
61
+ trendingSources: {
62
+ reddit: { enabled: true, subreddits: ["MachineLearning", "artificial", "ArtificialIntelligence", "deeplearning", "OpenAI", "LocalLLaMA", "singularity"], minScore: 100, maxAge: "24h" },
63
+ hackernews: { enabled: true, keywords: ["AI", "artificial intelligence", "machine learning", "deep learning", "GPT", "LLM", "OpenAI", "Anthropic", "Google AI", "neural network"], minPoints: 50 },
64
+ twitter: { enabled: false, accounts: ["AndrewYNg", "ylecun", "OpenAI", "AnthropicAI", "GoogleAI"], minLikes: 100, maxTweetsPerAccount: 5, maxAgeHours: 24, delayBetweenAccountsMs: 3000 }
65
+ },
66
+ trendAnalysis: { minTrendScore: 70, sourceDiversity: true, engagementWeight: 0.6, recencyWeight: 0.4 }
67
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aikeytake/social-automation",
3
- "version": "2.0.9",
3
+ "version": "2.1.0",
4
4
  "description": "Content research and aggregation tool for AI agents",
5
5
  "main": "src/index.js",
6
6
  "type": "module",
package/src/index.js CHANGED
@@ -7,13 +7,10 @@ import apiFetch from './fetchers/api.js';
7
7
  import fs from 'fs';
8
8
  import path from 'path';
9
9
  import { fileURLToPath } from 'url';
10
- import { createRequire } from 'module';
10
+ import defaultConfig from '../config/sources.js';
11
11
 
12
12
  dotenv.config();
13
13
 
14
- const require = createRequire(import.meta.url);
15
- const defaultConfig = JSON.parse(fs.readFileSync(require.resolve('@aikeytake/social-automation/config/sources.json'), 'utf-8'));
16
-
17
14
  const __dirname = path.dirname(fileURLToPath(import.meta.url));
18
15
  const logger = createLogger('Main');
19
16