Inspiration

Ecocité is the french word for "eco-city". The name of the project encapsulates the purpose - to encourage actions to improve the sustainability of our cities and towns.

What it does

Ecocité is a web application that accepts user location prompts for which intelligent sustainability insights are generated. A user may enter a specific location such as Oslo, Norway or a descriptive phrase such as "vast fjords" for which the system will generate a suitable location, e.g. a city in Norway, Sweden, Finland or Iceland. The system also allows for the user to view a 3D map of the location, exploring the place itself as well as its surroundings or even the entire globe.

How we built it

The application was built with Node.js as the backend server. The application uses a POST request endpoint at /api/locate to accept the user prompt, find an appropriate location and use Google Gemini to generate the precise city, country, latitude, longitude, description, sites and sustainability recommendations. The 3D map feature was made possible with Google's Photorealistic 3D Maps API. The frontend interface was built with HTML, CSS and JavaScript implementing browser features such as local storage to save the last generated location so that it appears by default every time the user revisits the application unless it is cleared. Node.js GET endpoints were used to serve these HTML files. The application comes with a ready Dockerfile so that an image may be built to containerize the app and deploy it with Kubernetes or a cloud service provider of your choice. Heroku was used to deploy the application.

Challenges we ran into

Using external APIs always come with the risk of server-side errors. For example, Gemini would often return a 503 error indicating that the model was overloaded. Furthermore, the Google Photorealistic 3D Maps API is still experimental, and so the map would sometimes lag. Nonetheless, we overcame some of these issues by improving the prompts for the Gemini model, making them clearer and more concise.

Accomplishments that we're proud of

We are proud to have a working full-stack application that is ready for quick deployment of its docker image. We successfully incorporated a functional frontend and backend, successfully connecting them to external APIs to build an impactful project focused on improving our cities and towns. Our system focuses on the pressing issue of the health of our natural and built environments. We hope our recommendations will be useful to government bodies, private bodies and individual people hoping to improve their cities and take small steps which add up to big leaps in bettering our surroundings.

What we learned

We learned how to incorporate multiple external APIs into a single application to enrich its features. Furthermore, we learned how to build a Node.js application to work as a full-stack application. In the past, we used Node.js as solely a backend, but we have learnt that Node.js can serve HTML files that contain prompt forms and display generated content at specified url paths on the server, essentially mimicking a full-stack application for our use case. This was interesting work.

What's next for Ecocité

Ecocité will further improve its map feature to include more data and interactions about specific locations, including eco-friendly driving routes, solar energy efficiency and air pollution levels.

Share this project:

Updates