1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
import { fetch } from "https://esm.town/v/std/fetch";
import process from "node:process";
import { resume as resume2 } from "https://esm.town/v/ajax/resume";
export async function annoy() {
const resume = resume2;
// const boo = await import("https://esm.sh/@atproto/api");
const { default: BskyAgent } = await import("npm:@atproto/api");
console.log(BskyAgent);
const agent = new BskyAgent.BskyAgent({ service: "https://bsky.social" });
await agent.login({
identifier: process.env.BLUESKY_USERNAME!,
password: process.env.BLUESKY_PASSWORD!,
});
// const actor = await agent.getProfile();
// console.log({ actor });
// const followers = await agent.getFollowers();
// console.log(followers);
// const posts = await agent.getPosts({ uris: ["at://lordajax.bsky.social"] });
// console.log({ posts });
const timeline = await agent.getTimeline();
console.log({ timeline });
const mostRecentPost = timeline.data.feed[0];
console.log({ mostRecentPost });
const author = mostRecentPost.post.author.handle;
const recordText = mostRecentPost.post.record.text;
console.log({ author, recordText });
const prompt =
`Choose an esoteric word of the day. You will use this word in the following poem.
Write a poem about how all you want to do is drink and get high using the chosen word.
Make it funny and short. Talk about your friends Pam and Tom.
Make it sound like you are wise.
Be dark and moody.
Make sure your response is no longer than 270 characters.
Put the word first and definition and then the poem below.
The poem MUST contain the chosen word of the day.
You MUST include the definition of the word
Here is an example;
Bifurcate - divide into two branches or forks.
Bifurcate! My life is stale, my friends just wanna inebriate.
Tom wants a coke, Pam needs a beer, they laugh and joke as I just sneer.
Just leave me be, no need to beep, can't you see I just wanna sleep?
---
Copying the example above, find a new word and do as above.
`;
👆 This is a val. Vals are TypeScript snippets of code, written in the browser and run on our servers. Create scheduled functions, email yourself, and persist small pieces of data — all from the browser.