Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CS2113-T11-2] Flirt & Fork #42

Open
wants to merge 468 commits into
base: master
Choose a base branch
from

Conversation

RyanTDL
Copy link

@RyanTDL RyanTDL commented Mar 7, 2024

Flirt & Fork helps generate creative and enjoyable date itineraries that fit within a specified budget, and are easily accessible from your current location

JeffinsonDarmawan pushed a commit to JeffinsonDarmawan/tp that referenced this pull request Mar 21, 2024
yeozongyao added a commit to yeozongyao/tp that referenced this pull request Mar 29, 2024
…yao-categoriseBooks

Update developer guide
Copy link

@nyh3 nyh3 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good Job! The developer guide is quite detailed. Some parts of the diagrams can be improved.


The following sequence diagram shows how `idea` causes various entities to interact with one another:

<img src="images/GenerateIdeaCommandSequenceDiagram.png">
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the class header format correct? Should it be :GenerateIdeaCommand?


The following sequence diagram shows how `idea` causes various entities to interact with one another:

<img src="images/GenerateIdeaCommandSequenceDiagram.png">
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the lifeline suppose to continue after the X (end of lifeline)?


Step 3. The execute method of ```GenerateSmartItineraryCommand``` is invoked. It retrieves the user's preferred location and cuisine from the ```UserDetails``` object. The method then filters the ```FoodList``` to find food options matching the user's preferences, ensures the selected food options are distinct, and randomly selects two activities from the ```ActivityList```. The generated itinerary, consisting of the selected food and activity options, is then output to the user.

![Smart Itinerary Generation Sequence Diagram](images/GenerateSmartItineraryCommandSequenceDiagram.png)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When the method is called, should there be a activation bar?


Step 3. The execute method of ```GenerateSmartItineraryCommand``` is invoked. It retrieves the user's preferred location and cuisine from the ```UserDetails``` object. The method then filters the ```FoodList``` to find food options matching the user's preferences, ensures the selected food options are distinct, and randomly selects two activities from the ```ActivityList```. The generated itinerary, consisting of the selected food and activity options, is then output to the user.

![Smart Itinerary Generation Sequence Diagram](images/GenerateSmartItineraryCommandSequenceDiagram.png)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should the return arrow be a dashed arrow?

|v1.0|busy user|effortlessly generate date ideas|not waste time endlessly searching for ideas|
|v1.0|budget conscious user|generate a date itinerary based on price|choose when to splurge and when to save|
|v1.0|user looking for variety|view a variety of date activities|enjoy diverse date experiences|
|v1.0|experienced user of the platform|save some of my preferred activities|reference back to them in future|

## Non-Functional Requirements

{Give non-functional requirements}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should there be explanation for non-functional requirements?


The following sequence diagram shows how `idea` causes various entities to interact with one another:

<img src="images/GenerateIdeaCommandSequenceDiagram.png">

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe can add in the the methods called and instances created in the diagram?
This can make the callings of such methods clearer for the developer

Step 2. The user enters the `"smart"` command to generate a personalized itinerary. The `"smart"` command is parsed by the ```parseCommand``` method in the ```Parser``` class, which creates a ```GenerateSmartItineraryCommand``` instance, passing the ```UserDetails``` object.

Step 3. The execute method of ```GenerateSmartItineraryCommand``` is invoked. It retrieves the user's preferred location and cuisine from the ```UserDetails``` object. The method then filters the ```FoodList``` to find food options matching the user's preferences, ensures the selected food options are distinct, and randomly selects two activities from the ```ActivityList```. The generated itinerary, consisting of the selected food and activity options, is then output to the user.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it better to create a class diagram here to visualise it?

The execute method of this command interacts with other components like `Ui` for input/output and `Storage` for persisting user data.
Below is the sequence of actions performed by the `UserDetailsCommand` to collect user information.

![User Details Collection Sequence Diagram](images/UserDetailsCommandSequenceDiagram.png)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image
Is this the appropriate way of showing the different alternate paths taken?
Rather a format like the picture below is better in showing the alternate paths taken.
image

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps c:UserDetailsCommand could be moved to the left, while u:UI be in the middle, such that the diagram can flow from left to right


### Feature Components and Interaction

The feature comprise several key components:

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps a sequence diagram could be added here?


- Changes to gift selections are persisted back to the `GiftList.txt` file via `Storage`, ensuring user choices are saved across different sessions.

#### Detailed Implementation

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe a class diagram can be added?

<img src="images/GenerateIdeaActivityDiagram.png" height = "375">

The following sequence diagram shows how `idea` causes various entities to interact with one another:

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image
Is this the correct way of showing the return of values? Should it be instead dotted lines to show the return?

Below is the sequence of actions performed by the `UserDetailsCommand` to collect user information.

![User Details Collection Sequence Diagram](images/UserDetailsCommandSequenceDiagram.png)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is straight lines the correct way to show return values instead of dotted lines?


#### Design Considerations

- Using a class hierarchy where `Gift` extends `Favourites` allows for easy addition of new types of favourites in the future.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Possibly add in class diagram?

- `GenerateGiftCommand` modifications: Revise this command to accept and process additional arguments for gender, altering the random gift selection logic to utilise the updated `getRandomGift` method in `GiftList`.

**User Interaction Flow**

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps add in sequence diagram?


## User Stories

|Version| As a ... | I want to ... | So that I can ...|
|--------|----------|---------------|------------------|
|v1.0|new user|see usage instructions|refer to them when I forget how to use the application|
|v2.0|user|find a to-do item by name|locate a to-do without having to go through the entire list|
|v1.0|first-time user|see a help message|know how to use the features within the app & its parameters|

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good job in adding in the user stories!

Copy link

@Aak242 Aak242 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall, very detailed DG with mostly correct diagrams!


The following sequence diagram shows how `idea` causes various entities to interact with one another:

<img src="images/GenerateIdeaCommandSequenceDiagram.png">
Copy link

@Aak242 Aak242 Apr 3, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Most details look correct on the sequence diagram, but should the X that represents deletion of the GenerateIdeaCommand have a lifeline or any further lines that continue after the X?

image


Step 3. The execute method of ```GenerateSmartItineraryCommand``` is invoked. It retrieves the user's preferred location and cuisine from the ```UserDetails``` object. The method then filters the ```FoodList``` to find food options matching the user's preferences, ensures the selected food options are distinct, and randomly selects two activities from the ```ActivityList```. The generated itinerary, consisting of the selected food and activity options, is then output to the user.

![Smart Itinerary Generation Sequence Diagram](images/GenerateSmartItineraryCommandSequenceDiagram.png)
Copy link

@Aak242 Aak242 Apr 3, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The previous diagram correctly represented return values with a dotted line (such as with getRandomActivity(). Should it be the same here, perhaps?

image

Personal details such as name, age, and gender are stored in a `UserDetails` object, which is then serialized to a file by `Storage`.
These operations are exposed in the system as follows:

The `UserDetailsCommand` is instantiated and called when the user chooses to enter or update their personal details.
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great descriptive explanation of the implemented feature and the relevant classes and methods!

The above sequence diagram depicts the interaction between UserDetailsCommand, the UI, and the Storage component, which highlights the flow of data collection and storage.


### [Proposed] History Tracking feature
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good job listing out your proposed features as well in addition to your existing implemented ones!

The execute method of this command interacts with other components like `Ui` for input/output and `Storage` for persisting user data.
Below is the sequence of actions performed by the `UserDetailsCommand` to collect user information.

![User Details Collection Sequence Diagram](images/UserDetailsCommandSequenceDiagram.png)
Copy link

@Aak242 Aak242 Apr 3, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps the alt could be split into separate if else statements with a more clear condition (for example, what "M", " R" or "D" refer to exactly
image

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps "M" or "R" or "D" could be made more obvious to the reader of the DG, maybe mention what M, R or D means under the diagram?

The above sequence diagram depicts the interaction between UserDetailsCommand, the UI, and the Storage component, which highlights the flow of data collection and storage.


### [Implemented] History Tracking feature
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Regarding the "history" command, perhaps this is not I what I would expect the command to do. Maybe "history" should show the user whole date that was generated together from generate idea?


Smart Itinerary Generation Feature: A proposed feature that creates personalized itineraries based on user preferences, ensuring variety and suitability.

History Tracking Feature: A proposed feature that keeps a record of past date activities, allowing users to track their date history and preferences.
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As mentioned above, I don't think it tracks each date history, it seems to just track which activities are completed?


Given below is an example usage scenario of how the History Tracking mechanism behaves at each step.

Step 1. The user launches the application and executes the `idea`/`itinerary`/`smart`/`gift` command. The relevant command is parsed by the `parseCommand` method in the `Parser` class, which creates a `GenerateIdeaCommand`/ `GenerateItineraryCommand`/`GenerateSmartItineraryCommand`/`GenerateGiftCommand` instance
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Its good to have this much detail! But I do think it might be a bit excessive to go through the geneate command here again?

RyanTDL and others added 24 commits April 10, 2024 00:15
Refactor itinerary generation and history function
Edit smart command portion in User Guide
Add Q&A section and legend for cuisine in User Guide
Fix error display messages, and add 'cancel' function to certain commands
liuy1103 and others added 30 commits April 15, 2024 14:47
Add clearer error handlings to parser class
Add additional line for UG command summary
…orUserDetails

Make integer inputs for user detail fields stricter
Fix minor cosmestics on display messages
Attempt to fix broken User Guide hyperlinks
update UG to standardise input format
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

9 participants