mirror of
https://github.com/freeCodeCamp/freeCodeCamp.git
synced 2026-04-12 01:00:13 -04:00
42 lines
2.4 KiB
Markdown
42 lines
2.4 KiB
Markdown
---
|
|
id: 5e46f8edac417301a38fb931
|
|
title: Clasificador de textos SMS basado en redes neuronales
|
|
challengeType: 10
|
|
forumTopicId: 462380
|
|
dashedName: neural-network-sms-text-classifier
|
|
---
|
|
|
|
# --description--
|
|
|
|
You will be <a href="https://colab.research.google.com/github/freeCodeCamp/boilerplate-neural-network-sms-text-classifier/blob/master/fcc_sms_text_classification.ipynb" target="_blank" rel="noopener noreferrer nofollow">working on this project with Google Colaboratory</a>.
|
|
|
|
Después de acceder al enlace, crea una copia del cuaderno ya sea en tu propia cuenta o de manera local. Una vez hayas completado el proyecto y superes el test (incluido en el enlace), envía el enlace del proyecto a continuación. Si envias un enlace a Google Colaboratory, asegúrate de que activas el uso compartido para "cualquiera con el enlace."
|
|
|
|
Todavía estamos desarrollando el contenido instructivo interactivo para el plan de estudios de aprendizaje automático. Por ahora, puedes pasar por los desafíos en video de esta certificación. También puede que tengas que buscar recursos de aprendizaje adicionales, similares a lo que harías cuando trabajas en un proyecto del mundo real.
|
|
|
|
# --instructions--
|
|
|
|
In this challenge, you need to create a machine learning model that will classify SMS messages as either "ham" or "spam". A "ham" message is a normal message sent by a friend. A "spam" message is an advertisement or a message sent by a company.
|
|
|
|
You should create a function called `predict_message` that takes a message string as an argument and returns a list. The first element in the list should be a number between zero and one that indicates the likeliness of "ham" (0) or "spam" (1). The second element in the list should be the word "ham" or "spam", depending on which is most likely.
|
|
|
|
For this challenge, you will use the <a href="http://www.dt.fee.unicamp.br/~tiago/smsspamcollection/" target="_blank" rel="noopener noreferrer nofollow">SMS Spam Collection</a> dataset. The dataset has already been grouped into train data and test data.
|
|
|
|
The first two cells import the libraries and data. The final cell tests your model and function. Add your code in between these cells.
|
|
|
|
# --hints--
|
|
|
|
It should pass all Python tests.
|
|
|
|
```js
|
|
|
|
```
|
|
|
|
# --solutions--
|
|
|
|
```py
|
|
# Python challenges don't need solutions,
|
|
# because they would need to be tested against a full working project.
|
|
# Please check our contributing guidelines to learn more.
|
|
```
|