This commit is contained in:
Morten Olsen
2024-04-19 20:51:52 +02:00
committed by Morten Olsen
parent 98e39a54cc
commit ee37ac9d90
51 changed files with 604 additions and 798 deletions

View File

@@ -6,11 +6,11 @@ color: '#e7d9ac'
heroImage: ./assets/cover.png
---
import { Image } from 'astro:assets';
import TaskBounds from './assets/TaskBounds.png';
import Frame1 from './assets/Frame1.png';
import Graph1 from './assets/Graph1.png';
import Graph2 from './assets/Graph2.png';
import { Image } from 'astro:assets'
import TaskBounds from './assets/TaskBounds.png'
import Frame1 from './assets/Frame1.png'
import Graph1 from './assets/Graph1.png'
import Graph2 from './assets/Graph2.png'
Allow me to introduce Bob. Bob is an algorithm, and he has just accepted a role as my assistant.
@@ -26,7 +26,7 @@ Also, I wanted a planning algorithm that was not only for productivity. I did no
Bob is still pretty young and still learning new things, but he has gotten to the point where I believe he is good enough to start to use on a day to day basis.
<Image src={Frame1} alt="Frame1" />
<Image src={Frame1} alt='Frame1' />
How does Bob work? Bob gets a list of tasks, some from my calendar (both my work and my personal calendar), some from "routines" (which are daily tasks that I want to do most days, such as eating breakfast or picking up the kid), and some tasks come from "goals" which are a list of completable items. These tasks go into Bob, and he tries to create a plan for the next couple of days where I get everything done that I set out to do.
@@ -38,7 +38,7 @@ An "earliest start time" and a "latest start time". These define when the task c
- If the task is required.
- A priority
<Image src={TaskBounds} alt="Task bounds" />
<Image src={TaskBounds} alt='Task bounds' />
Bob uses a graph walk to create the optimal plan, where each node contains a few different things
@@ -53,11 +53,11 @@ Bob starts by figuring out which locations I can go to complete the remaining ta
He then gets a list of all the remaining tasks for the current node which can be completed at the current location, again figuring out when I would be done with the task, updating the list of impossible tasks and scoring the node.
If any node adds a required task to the impossible list, that node is considered dead, and Bob will not analyze it further.
<Image src={Graph1} alt="Graph1" />
<Image src={Graph1} alt='Graph1' />
Now we have a list of active leaves, and from that list, we find the node with the highest score and redo the process from above.
<Image src={Graph2} alt="Graph2" />
<Image src={Graph2} alt='Graph2' />
Bob has four different strategies for finding a plan.

View File

@@ -6,8 +6,8 @@ description: ''
heroImage: ./assets/cover.png
---
import graph from './assets/graph.png';
import { Image } from 'astro:assets';
import graph from './assets/graph.png'
import { Image } from 'astro:assets'
I have been playing around with smart homes for a long time; I have used most of the platforms out there, I have developed quite a few myself, and one thing I keep coming back to is Redux.
@@ -66,7 +66,7 @@ Now comes the part I have feared, where I need to draw a diagram.
...sorry
<Image src={graph} alt="graph" />
<Image src={graph} alt='graph' />
So this shows our final setup.

View File

@@ -1,4 +1,4 @@
import { defineCollection, z } from 'astro:content';
import { defineCollection, z } from 'astro:content'
const articles = defineCollection({
schema: ({ image }) =>
@@ -10,10 +10,10 @@ const articles = defineCollection({
updatedDate: z.coerce.date().optional(),
tags: z.array(z.string()).optional(),
heroImage: image().refine((img) => img.width >= 320, {
message: 'Cover image must be at least 1080 pixels wide!',
}),
}),
});
message: 'Cover image must be at least 1080 pixels wide!'
})
})
})
const work = defineCollection({
schema: ({ image }) =>
@@ -26,16 +26,16 @@ const work = defineCollection({
url: z.string().optional(),
logo: image()
.refine((img) => img.width >= 200, {
message: 'Logo must be at least 320 pixels wide!',
message: 'Logo must be at least 320 pixels wide!'
})
.optional(),
banner: image()
.refine((img) => img.height >= 50, {
message: 'Logo must be at least 320 pixels wide!',
message: 'Logo must be at least 320 pixels wide!'
})
.optional(),
}),
});
.optional()
})
})
const references = defineCollection({
schema: () =>
@@ -45,16 +45,16 @@ const references = defineCollection({
company: z.string(),
date: z.coerce.date(),
relation: z.string(),
profile: z.string(),
}),
});
profile: z.string()
})
})
const skills = defineCollection({
schema: () =>
z.object({
name: z.string(),
technologies: z.array(z.string()),
}),
});
technologies: z.array(z.string())
})
})
export const collections = { articles, work, references, skills };
export const collections = { articles, work, references, skills }

View File

@@ -1,6 +1,6 @@
import type { ResumeSchema } from '@/types/resume-schema.js';
import { Content } from './description.md';
import image from './profile.jpg';
import type { ResumeSchema } from '@/types/resume-schema.js'
import { Content } from './description.md'
import image from './profile.jpg'
const basics = {
name: 'Morten Olsen',
@@ -11,38 +11,38 @@ const basics = {
location: {
city: 'Copenhagen',
countryCode: 'DK',
region: 'Capital Region of Denmark',
region: 'Capital Region of Denmark'
},
profiles: [
{
network: 'GitHub',
icon: 'mdi:github',
username: 'morten-olsen',
url: 'https://github.com/morten-olsen',
url: 'https://github.com/morten-olsen'
},
{
network: 'LinkedIn',
icon: 'mdi:linkedin',
username: 'mortenolsendk',
url: 'https://www.linkedin.com/in/mortenolsendk',
},
url: 'https://www.linkedin.com/in/mortenolsendk'
}
],
languages: [
{
name: 'English',
fluency: 'Conversational',
fluency: 'Conversational'
},
{
name: 'Danish',
fluency: 'Native speaker',
},
],
} satisfies ResumeSchema['basics'];
fluency: 'Native speaker'
}
]
} satisfies ResumeSchema['basics']
const profile = {
basics,
image,
Content,
};
Content
}
export { profile };
export { profile }