Preheat the oven to 400°F. Cut the spaghetti squash in half lengthwise and scoop out the seeds. Brush the cut sides lightly with olive oil and place the squash halves cut-side down on a parchment-lined baking sheet.
Roast for 35–40 minutes, until the flesh is tender and easily shreds with a fork. Set aside to cool slightly, then scrape the squash into strands and place in a bowl.
While the squash roasts, heat a drizzle of olive oil in a large skillet or Dutch oven over medium heat. Add the diced onion, carrots, and celery and cook for 5–7 minutes, until softened. Stir in the garlic and cook for 30–60 seconds, until fragrant.
Add the ground beef and cook, breaking it up with a spoon, until browned and cooked through. Pour in the red wine and let it simmer for 2–3 minutes, allowing the alcohol to cook off.
Stir in the diced tomatoes, vegetable broth, tomato paste, oregano, and thyme. Season with salt and pepper to taste. Bring the sauce to a gentle simmer and cook for 15–20 minutes, stirring occasionally, until thickened and flavorful.
Divide the spaghetti squash among serving bowls and spoon the bolognese sauce over the top. Garnish with grated Parmesan or fresh basil, if desired, and serve warm.