In a large sauté pan with a lid or a Dutch oven, warm the oil over medium heat. Add the onion, garlic, celery, carrot, and chard stems. Cook, stirring frequently, for 10 minutes. Stir in the red pepper flakes, cook for 30 seconds, then stir in the tomato paste and 1 cup water. Bring to a boil, then lower the heat to medium-low and simmer, uncovered, for 10 minutes. Stir in the chard leaves by the handful, letting each addition cook down a bit before adding the next. Stir in the beans. Cover and cook until the greens are very soft, about 10 minutes more. Season to taste with salt and pepper and serve.